diff --git a/checkstyle/checkstyle-header.txt b/checkstyle/checkstyle-header.txt new file mode 100644 index 0000000000000000000000000000000000000000..d973dcedae5d02b9655ee2d12c1ad494d3608778 --- /dev/null +++ b/checkstyle/checkstyle-header.txt @@ -0,0 +1,16 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ \ No newline at end of file diff --git a/checkstyle/checkstyle.xml b/checkstyle/checkstyle.xml new file mode 100644 index 0000000000000000000000000000000000000000..bdb5300619dd56213e9859dc679f7b4f2146e133 --- /dev/null +++ b/checkstyle/checkstyle.xml @@ -0,0 +1,180 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pom.xml b/pom.xml index 6829fc1f576ed5234bedf9a111890bd4e05c4566..79f72c1a077bf7449c38eba510506d690b77238d 100644 --- a/pom.xml +++ b/pom.xml @@ -273,6 +273,30 @@ true + + + org.apache.maven.plugins + maven-checkstyle-plugin + 3.1.0 + + checkstyle/checkstyle.xml + false + true + UTF-8 + false + error + false + + + + validate + validate + + checkstyle + + + + diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncConfig.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncConfig.java index b6ef5a9bd1245cc3aea9c01df475892e94dc25a8..8739a3385fce45c28fbe8ba42e21958d5ef0d59c 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncConfig.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncConfig.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.async; import java.util.concurrent.Executor; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncHelper.java index d23fef408bc12ecd3d790dcd99ac5300c3637a48..530926c363b41cda5a42dd5399a5da0227ce18ee 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.async; import org.dromara.streamquery.stream.core.lambda.function.SerFunc; @@ -13,7 +29,7 @@ import java.util.concurrent.CompletableFuture; */ public class AsyncHelper { - public static AsyncConfig defaultConfig = AsyncConfig.create(); + private static final AsyncConfig DEFAULT_CONFIG = AsyncConfig.create(); private AsyncHelper() { /* Do not new me! */ @@ -21,7 +37,7 @@ public class AsyncHelper { @SafeVarargs public static List supply(SerSupp... suppliers) { - return supply(defaultConfig, suppliers); + return supply(DEFAULT_CONFIG, suppliers); } @SafeVarargs diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncInterceptor.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncInterceptor.java index 436591ec0919ffed0860f516623cc890199ca794..0c4d47526909187bd908fa58c826941208b83d0b 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncInterceptor.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/async/AsyncInterceptor.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.async; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/bean/BeanHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/bean/BeanHelper.java index 88feecd8b3fe30d1ea0da77024c799ecad411dda..f81db177372e5e78fe1bb84320415cc9ef288ee8 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/bean/BeanHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/bean/BeanHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.bean; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/FoundWord.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/FoundWord.java index 7db5ab24f5662ad128a9c551b93dd6746b906c0e..5e12f29013345235d8cc0a9e8927ad53cee1f8b7 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/FoundWord.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/FoundWord.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.business.highlight; /** diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelper.java index f5bb4b6f33113a7312fb3338ce535ac2a8cb3d68..f2d050b479be84bcf7e9f0572fb21ef202b50236 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.business.highlight; import org.dromara.streamquery.stream.core.optional.Opp; @@ -13,7 +29,6 @@ import java.util.function.UnaryOperator; * 高亮封装 * * @author VampireAchao Cizai_ - */ public class HighlightHelper { @@ -53,7 +68,7 @@ public class HighlightHelper { // 获取要从哪里开始保留 int index = fondWord.getWord().indexOf(last.getWord().charAt(last.getWord().length() - 1)); // 这里没有判断是否找到是因为只要进入当前的if语句那么必定有重复串可以找到 - String suffix = fondWord.getWord().substring(index+1); + String suffix = fondWord.getWord().substring(index + 1); word = last.getWord() + suffix; } else { // 否则根据历史下标到当前词汇下标进行查找额外部分 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/tree/TreeHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/tree/TreeHelper.java index d885b6d45c343ded695aaf6e0f056909945ec5dd..5517efd7586adffb59f9baf59171ebceb6d0b047 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/tree/TreeHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/business/tree/TreeHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.business.tree; import org.dromara.streamquery.stream.core.lambda.function.SerBiCons; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/clazz/ClassHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/clazz/ClassHelper.java index 7079032e221789f55f97fecad0b7b14ffb0dca35..e0cb6f9fe4f76ae62ce3bf14c6b762cf192d63a5 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/clazz/ClassHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/clazz/ClassHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.clazz; import org.dromara.streamquery.stream.core.lambda.function.SerFunc; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Lists.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Lists.java index 6a7facaf56fc333b015095e6cd5877879f26de14..ca8ed126216d3088672c518d7a813ebc7cda6f29 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Lists.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Lists.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.collection; import java.util.*; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Maps.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Maps.java index 2fc8e56a0ba20b5884db0f8081ea536cdae7b735..3fd18283354ac4115b78dc272a5de03b9f7edbd8 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Maps.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Maps.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.collection; import org.dromara.streamquery.stream.core.stream.Steam; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Sets.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Sets.java index 25921273ad6b9ef06b190ac2f4cbf3c8a3e9fca9..78909ed589ef7a12babc342dac9bc664149ac44e 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Sets.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/collection/Sets.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.collection; import java.util.*; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaExecutable.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaExecutable.java index 19848133d34545bec7840745c9660f41e6df841c..85bf38b654776ad1ddfa2f57cd3e02e95d1f387f 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaExecutable.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaExecutable.java @@ -1,11 +1,10 @@ /* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -15,7 +14,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - package org.dromara.streamquery.stream.core.lambda; import org.dromara.streamquery.stream.core.reflect.ReflectHelper; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaHelper.java index 6e149118a40cda97f6aeae0d449e042350d9e6e5..5819f26c9fc1097a470c3fc75d9e9b4d6d095b8a 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda; import org.dromara.streamquery.stream.core.bean.BeanHelper; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaInvokeException.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaInvokeException.java index d2e1fc7b3eabc56a1098baf8faa275b57910fd09..d6699ce16be909ba22f847517ee2fbdd32a71cb8 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaInvokeException.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/LambdaInvokeException.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda; /** diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsCons.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsCons.java index ddf0021909585f48c037a02bdc75112d1dba2ed5..93031769baa7b012d3f93876cfc6514179336d3e 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsCons.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsCons.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -9,6 +25,7 @@ import java.util.stream.Stream; /** * SerArgsSerArgsCons * + * @param the type of the input to the operation * @author VampireAchao Cizai_ * @since 2022/6/8 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsFunc.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsFunc.java index 86fe0ebea3c0fa5b6b8efdf26a29ef7e621698a4..51ff937aa5d974d99f36ab87276901f1bbced7c2 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsFunc.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsFunc.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -8,6 +24,8 @@ import java.util.Objects; /** * 可序列化的SerArgsFunc * + * @param the type of the input to the operation + * @param the type of the result of the operation * @author VampireAchao Cizai_ * @see SerArgsFunc diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsPred.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsPred.java index b3a02e1ebe06920c16e27b0e5ce1dd729276afcc..00e9a74571f52a0863576ff90628732ae02f0f91 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsPred.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsPred.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -10,6 +26,7 @@ import java.util.stream.Stream; /** * 可序列化的Predicate * + * @param the type of the input to the operation * @author VampireAchao Cizai_ * @see Predicate diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsUnOp.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsUnOp.java index ab1fc0e626a9a7ac6b446d997507901161bf991b..f25e29e675e0409433d9be926d67f2e24c005dc8 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsUnOp.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerArgsUnOp.java @@ -1,8 +1,25 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; /** * SerArgsUnOp * + * @param the type of the input and output of the operator * @author VampireAchao Cizai_ * @since 2022/6/8 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiCons.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiCons.java index d06d16355de6298f3c946b94428204d2e80afcdb..d89821a881ee87db65fa02dc0d31169604c5d6d4 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiCons.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiCons.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -9,7 +25,8 @@ import java.util.stream.Stream; /** * SerSerBiCons - * + * @param a T class + * @param a U class * @author VampireAchao Cizai_ * @since 2022/6/8 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiFunc.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiFunc.java index c3429168992d01d441e7589115bce47d7c9d6081..482e5cbb3258d9c9be2ff479db91b1562fe53cad 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiFunc.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiFunc.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -9,6 +25,9 @@ import java.util.function.BiFunction; /** * SerBiFunc * + * @param the type of the first argument to the function + * @param the type of the second argument to the function + * @param the type of the result of the function * @author VampireAchao Cizai_ * @since 2022/6/8 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiOp.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiOp.java index b780dcb7cf43b5be132bbadb732144b40be3874a..21722ecd0fb9f41fb56bcc17d6119c3230072269 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiOp.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiOp.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -10,6 +26,7 @@ import java.util.function.BinaryOperator; /** * SerBiUnOp * + * @param the type of the input to the operation * @author VampireAchao Cizai_ * @since 2022/6/8 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiPred.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiPred.java index 4b8382ac2d580f80fd38eef10ae874b8a06f4971..ea2a0d6c6b20ea045982fb277b2e5341dc9e108b 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiPred.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerBiPred.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -9,6 +25,8 @@ import java.util.function.BiPredicate; /** * SerBiPred * + * @param the type of the first input to the predicate + * @param the type of the second input to the predicate * @author VampireAchao Cizai_ * @since 2022/6/8 diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerCons.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerCons.java index 06729869162b786b73b035acb4ed1431d59fc240..77851f55ae055606812cb9a494b698a941475ccf 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerCons.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerCons.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -10,6 +26,7 @@ import java.util.stream.Stream; /** * 可序列化的Consumer * + * @param the type of the input to the operation * @author VampireAchao Cizai_ * @see java.util.function.Consumer diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerFunc.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerFunc.java index b5257d7550251830e5de8fc91da42ac491a5c0b2..f1c1cfd3a0d4bd5e0def34cdf0698aa78b82d7a8 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerFunc.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerFunc.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -8,8 +24,10 @@ import java.util.function.Function; /** * 可序列化的Function * + * @param the type of the input to the function + * @param the type of the result of the function * @author VampireAchao Cizai_ - + * * @see java.util.function.Function */ @FunctionalInterface diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerPred.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerPred.java index 121df21c2085a9f1d9e04b838c6695f0519c0121..7994c0f861bfc63d28f0e4eb18552905c9a33037 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerPred.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerPred.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -10,6 +26,7 @@ import java.util.stream.Stream; /** * 可序列化的Predicate * + * @param the type of the input to the predicate * @author VampireAchao Cizai_ * @see java.util.function.Predicate diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerRunn.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerRunn.java index 75a6bd7b2f61731daf25fec6b602f1bee740f32e..eb45d6dc632a611c8dd38f67a597c316c58a30a0 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerRunn.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerRunn.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerSupp.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerSupp.java index 8b6b9de8f3ebb03280b91858fcf2d99e7cc3f95b..b2cf76deed438ac5611bbd4d05d6dea0cc914555 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerSupp.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerSupp.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -9,6 +25,7 @@ import java.util.stream.Stream; /** * 可序列化的Supplier * + * @param the type of results supplied by this supplier * @author VampireAchao Cizai_ * @see java.util.function.Supplier diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerUnOp.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerUnOp.java index 177b9149e5f1561c7963a96e63135297e6c35c70..e71c1cec250f72e920f8c366339825bf54943116 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerUnOp.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/lambda/function/SerUnOp.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.dromara.streamquery.stream.core.lambda.LambdaInvokeException; @@ -9,8 +25,8 @@ import java.util.function.UnaryOperator; /** * 可序列化的UnaryOperator * + * @param the type of the input and output of the operator * @author VampireAchao Cizai_ - * @see java.util.function.UnaryOperator */ @FunctionalInterface diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Opp.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Opp.java index b559ef2e41c9f0eed931066c856f9606d25ba276..269b7b5b0e2ad38832aa9525e2ae3683d1ed2e26 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Opp.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Opp.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.optional; import org.dromara.streamquery.stream.core.lambda.LambdaExecutable; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Sf.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Sf.java index 256f3b14725a4f414d9ce47a9627fcabd6d50c0b..e7a547b49df762964a6daab8e892a2c9c320dd97 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Sf.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/optional/Sf.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.optional; import org.dromara.streamquery.stream.core.lambda.function.SerCons; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReference.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReference.java index 8e2edf39a4111895c55984145e6f498eceaf310c..1c345db784eb39dca73e33aa640274fffa8a7570 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReference.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReference.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.reflect; import java.lang.reflect.Type; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/ReflectHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/ReflectHelper.java index 668bc99d5525c7c3fba750de68273e7e9bcb291b..ae484a2872f45ff33fb6de9e51c3140f39771546 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/ReflectHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/reflect/ReflectHelper.java @@ -1,11 +1,10 @@ /* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -36,12 +35,11 @@ import java.util.logging.Logger; * 反射工具类 * * @author VampireAchao Cizai_ - * @since 2022/6/2 17:02 */ public class ReflectHelper { - private static final Logger logger = Logger.getAnonymousLogger(); + private static final Logger LOGGER = Logger.getAnonymousLogger(); /** * Constant LEFT_MIDDLE_BRACKET="[" @@ -256,8 +254,8 @@ public class ReflectHelper { method -> Arrays.equals(method.getParameterTypes(), parameterTypes) )).findFirst().map(ReflectHelper::accessible).orElseThrow(() -> new IllegalArgumentException( String.format("No such method: %s args: %s", - methodName - , Steam.of(parameterTypes).map(Type::getTypeName).join(",")))); + methodName, + Steam.of(parameterTypes).map(Type::getTypeName).join(",")))); } /** @@ -513,13 +511,13 @@ public class ReflectHelper { * @param obj a {@link java.lang.Object} object */ public static void explain(Object obj) { - logger.info(() -> "obj: " + obj + " class: " + obj.getClass()); - logger.info(() -> "fields: "); - Steam.of(getFields(obj.getClass())).map(Field::getName).forEach(fieldName -> logger.info(() -> "field " + + LOGGER.info(() -> "obj: " + obj + " class: " + obj.getClass()); + LOGGER.info(() -> "fields: "); + Steam.of(getFields(obj.getClass())).map(Field::getName).forEach(fieldName -> LOGGER.info(() -> "field " + "" + fieldName + ": " + getFieldValue(obj, fieldName))); - logger.info(() -> "no arg methods: "); + LOGGER.info(() -> "no arg methods: "); Steam.of(getMethods(obj.getClass())).map(Method::getName).forEach(methodName -> - logger.info(() -> "method " + methodName + ": " + Opp.ofTry(() -> + LOGGER.info(() -> "method " + methodName + ": " + Opp.ofTry(() -> getMethod(obj.getClass(), methodName).invoke(obj)))); } } diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/AbstractStreamWrapper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/AbstractStreamWrapper.java index d0fae27b6fe2584bfaf6b2aea81f5c9aa223fa95..bd9ef04ba3e366ae3d6206d602e6263095091a63 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/AbstractStreamWrapper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/AbstractStreamWrapper.java @@ -1,8 +1,42 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.stream; -import java.util.*; -import java.util.function.*; -import java.util.stream.*; +import java.util.Comparator; +import java.util.Iterator; +import java.util.Objects; +import java.util.Optional; +import java.util.Spliterator; +import java.util.function.BiConsumer; +import java.util.function.BiFunction; +import java.util.function.BinaryOperator; +import java.util.function.Consumer; +import java.util.function.Function; +import java.util.function.IntFunction; +import java.util.function.Predicate; +import java.util.function.Supplier; +import java.util.function.ToDoubleFunction; +import java.util.function.ToIntFunction; +import java.util.function.ToLongFunction; +import java.util.stream.Collector; +import java.util.stream.DoubleStream; +import java.util.stream.IntStream; +import java.util.stream.LongStream; +import java.util.stream.Stream; /** * {@link Stream}的包装类,用于基于一个已有的流实例进行扩展 @@ -150,9 +184,9 @@ abstract class AbstractStreamWrapper> implements Stream{@code * .of("one", "two", "three", "four") * .filter(e -> e.length() > 3) - * .peek(e -> System.out.println("Filtered value: " + e)) + * .peek(e -> log.info("Filtered value: " + e)) * .map(String::toUpperCase) - * .peek(e -> System.out.println("Mapped value: " + e)) + * .peek(e -> log.info("Mapped value: " + e)) * .collect(Collectors.toList()); * } */ diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/CollectableStream.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/CollectableStream.java index beb99ee29ab7bdfad9b034a16d56a92d99aeb15c..6e93cb6d60dcec32e4a3af2237eefc0abc5d51ab 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/CollectableStream.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/CollectableStream.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.stream; import org.dromara.streamquery.stream.core.optional.Opp; @@ -15,8 +31,8 @@ import java.util.stream.Stream; /** * 允许实现类直接跳过{@link java.util.stream.Stream#collect(Collector)}使用{@link java.util.stream.Collector}中一些常用方法 * + * @param 元素类型 * @author huangchengxing - */ public interface CollectableStream extends Stream { diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/Steam.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/Steam.java index 398af27b2345192af0a6527634cf5091cb15be12..74ca27c6e7d9ee3fff9b6aebbde29672b4c200e1 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/Steam.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/Steam.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.stream; import org.dromara.streamquery.stream.core.collection.Maps; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/collector/Collective.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/collector/Collective.java index 00047f715f113ec7400ec6956fa1ff45911bc472..5811012baec30dafd8128365a9c837b6f31c4c75 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/collector/Collective.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/stream/collector/Collective.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.stream.collector; import org.dromara.streamquery.stream.core.lambda.function.SerBiOp; diff --git a/stream-core/src/main/java/org/dromara/streamquery/stream/core/variable/VariableHelper.java b/stream-core/src/main/java/org/dromara/streamquery/stream/core/variable/VariableHelper.java index 03393c26ff313be8cabfedbf4e4c49f0f5e97844..2d20bea917ff99f1434712017ee821d867874fc4 100644 --- a/stream-core/src/main/java/org/dromara/streamquery/stream/core/variable/VariableHelper.java +++ b/stream-core/src/main/java/org/dromara/streamquery/stream/core/variable/VariableHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.variable; import org.dromara.streamquery.stream.core.stream.Steam; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/async/AsyncHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/async/AsyncHelperTest.java index d10ef244e1ab898ac90c7ab21ed47c178634dc6f..927f5ebf67c8dc57ab9cc8ae3d259308090e70a8 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/async/AsyncHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/async/AsyncHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.async; import com.alibaba.ttl.TransmittableThreadLocal; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/bean/BeanHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/bean/BeanHelperTest.java index 5e19ca7b15bb7475775555f1fa95cd3e489c0c6e..912d58cf80cb101fe5bf05007ceead06eab671dc 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/bean/BeanHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/bean/BeanHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.bean; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelperTest.java index ee4f7c658ce011e2dcff51e73cd696dd9293346b..d42715d27e43074961733bb1a19836ace77cfaf5 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/highlight/HighlightHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.business.highlight; import org.dromara.streamquery.stream.core.collection.Lists; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/tree/TreeHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/tree/TreeHelperTest.java index 989839de1a201aa0ef84942e2836f4f7b28c77ce..e013c2b69a4c2c0ceb05159c077e726ea9133a89 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/tree/TreeHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/business/tree/TreeHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.business.tree; import lombok.Builder; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/clazz/ClassHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/clazz/ClassHelperTest.java index d4260c6fe613fb3893f4ee47c779398f8d89d016..e0357bb12d9151a92abe255fab4238e078336a57 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/clazz/ClassHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/clazz/ClassHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.clazz; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/ListsTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/ListsTest.java index efd45459119f73e27732aa2b7851a1f13ded9560..c76bf9e3c52554d97905839d0ad2a7700e43b3a9 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/ListsTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/ListsTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.collection; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/MapsTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/MapsTest.java index 56acc094c9aab1698a5155379a346091b6da8d29..28ba4bcab2d1a6394037f982fc4a94d4dccb90f8 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/MapsTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/MapsTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.collection; import org.dromara.streamquery.stream.core.stream.Steam; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/SetsTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/SetsTest.java index 33451d3e2859040562af50b0eeeb28f2b6434dd5..c7ee77c9636b4d726c6362d2a58b07131eb1952c 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/SetsTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/collection/SetsTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.collection; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/LambdaHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/LambdaHelperTest.java index a410d87e09abd5644562820a1bc9c9b7d7738756..196bbb95672471940c1dff597593d7d4d4beeb87 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/LambdaHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/LambdaHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda; import lombok.SneakyThrows; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/function/SerConsTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/function/SerConsTest.java index f704c9e0435de4552bcc5cb01b916074e22bde3e..f103beea4e994a637bf47fd8f086f51b6e61a852 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/function/SerConsTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/lambda/function/SerConsTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.lambda.function; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/OppTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/OppTest.java index 2d66d53c9657391f6b14285c0c4c9a7d4941e12a..89c3592a1629e90e723f97401ad4f32a6eea0987 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/OppTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/OppTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.optional; import lombok.AllArgsConstructor; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/SfTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/SfTest.java index fa8eb4e7317e6514e72bdbad7d8975c761681375..31655a7bd6cec9e2612ec8630751bb26592e04b8 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/SfTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/optional/SfTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.optional; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReferenceTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReferenceTest.java index 69c2644a3e4c484c288c94f6e0752f2c6cdbda58..3bd53c98a269d859420b1ad85c9014b73f42a961 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReferenceTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/AbstractTypeReferenceTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.reflect; import org.junit.jupiter.api.Assertions; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/ReflectHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/ReflectHelperTest.java index 8a848ce954db5518869ab9a9bca2962dc86bbfd6..120fb9398d9596e4009e2482d5703d042caa33cf 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/ReflectHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/reflect/ReflectHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.reflect; import org.dromara.streamquery.stream.core.lambda.LambdaHelper; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/SteamTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/SteamTest.java index 6f168a7338718192060e5d1b8eda6091e687d979..873d9f8bdf78c6c379d729660d10e9ca43cf75cd 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/SteamTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/SteamTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.stream; import lombok.Builder; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/collector/CollectiveTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/collector/CollectiveTest.java index 2bf96c2655bfdc91363f1d6db85dacc47c2e5d59..2034b64320f8ed181e74b49a99f3054fab6a76f3 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/collector/CollectiveTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/stream/collector/CollectiveTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.stream.collector; import org.dromara.streamquery.stream.core.stream.Steam; diff --git a/stream-core/src/test/java/org/dromara/streamquery/stream/core/variable/VariableHelperTest.java b/stream-core/src/test/java/org/dromara/streamquery/stream/core/variable/VariableHelperTest.java index a4377ac57e185d0d580b8891abcb46ba74cd3657..53c239609919819a1cd850704d9c17fdaeb582fa 100644 --- a/stream-core/src/test/java/org/dromara/streamquery/stream/core/variable/VariableHelperTest.java +++ b/stream-core/src/test/java/org/dromara/streamquery/stream/core/variable/VariableHelperTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.core.variable; import org.junit.jupiter.api.Assertions; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQuery.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQuery.java index d4950282c1734e5e0b0f7cf48b96b99271b6d054..d71d6f516b14171a89b31e9ad9c908719f327f26 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQuery.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQuery.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQueryHelper.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQueryHelper.java index cf9fec89aea75946af78400443ef958d7d2d5727..0c7928e523e475045cc97a553492d9fb914649c4 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQueryHelper.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/BaseQueryHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Database.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Database.java index 089813e7a8a4c6151d25c8455891a04275779a30..77283e434a0bb4f18dd6b240f301f57bb65a6165 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Database.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Database.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.MybatisConfiguration; @@ -55,7 +71,7 @@ import java.util.stream.Stream; * @since 1.0 */ public class Database { - private static final Log log = LogFactory.getLog(Database.class); + private static final Log LOG = LogFactory.getLog(Database.class); private static final Map, Map> TABLE_PROPERTY_COLUMN_CACHE = new ConcurrentHashMap<>(); private static final Map, Map> TABLE_COLUMN_PROPERTY_CACHE = new ConcurrentHashMap<>(); @@ -250,7 +266,7 @@ public class Database { Class entityClass = getEntityClass(entityList); Class mapperClass = getMapperClass(entityClass); String sqlStatement = SqlHelper.getSqlStatement(mapperClass, SqlMethod.INSERT_ONE); - return SqlHelper.executeBatch(entityClass, log, entityList, batchSize, + return SqlHelper.executeBatch(entityClass, LOG, entityList, batchSize, (sqlSession, entity) -> sqlSession.insert(sqlStatement, entity)); } @@ -394,7 +410,7 @@ public class Database { Class mapperClass = getMapperClass(entityClass); String keyProperty = tableInfo.getKeyProperty(); Assert.notEmpty(keyProperty, "error: can not execute. because can not find column for primary key from entity!"); - return SqlHelper.saveOrUpdateBatch(entityClass, mapperClass, log, entityList, batchSize, + return SqlHelper.saveOrUpdateBatch(entityClass, mapperClass, LOG, entityList, batchSize, (sqlSession, entity) -> { Object idVal = tableInfo.getPropertyValue(entity, keyProperty); return StringUtils.checkValNull(idVal) @@ -537,7 +553,7 @@ public class Database { Class entityClass = getEntityClass(entityList); Class mapperClass = getMapperClass(entityClass); String sqlStatement = SqlHelper.getSqlStatement(mapperClass, SqlMethod.UPDATE_BY_ID); - return SqlHelper.executeBatch(entityClass, log, entityList, batchSize, (sqlSession, entity) -> { + return SqlHelper.executeBatch(entityClass, LOG, entityList, batchSize, (sqlSession, entity) -> { MapperMethod.ParamMap param = new MapperMethod.ParamMap<>(); param.put(Constants.ENTITY, entity); sqlSession.update(sqlStatement, param); @@ -649,7 +665,7 @@ public class Database { if (throwEx) { return execute(entityClass, baseMapper -> baseMapper.selectOne(queryWrapper)); } - return execute(entityClass, baseMapper -> SqlHelper.getObject(log, baseMapper.selectList(queryWrapper))); + return execute(entityClass, baseMapper -> SqlHelper.getObject(LOG, baseMapper.selectList(queryWrapper))); } /** @@ -689,7 +705,7 @@ public class Database { */ public static Map getMap(AbstractWrapper queryWrapper) { return execute(getEntityClass(queryWrapper), baseMapper -> activeOrElse(queryWrapper, - w -> SqlHelper.getObject(log, baseMapper.selectMaps(w)), null)); + w -> SqlHelper.getObject(LOG, baseMapper.selectMaps(w)), null)); } /** diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Many.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Many.java index da142453e145bd426f85dca3a5f8fe317d4d4861..29aea573fd67f66ac75b9d8ee272291667977adb 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Many.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/Many.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.toolkit.support.SFunction; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/One.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/One.java index 4b7d52d58cb4c5c2211af5be605c68e43e48c831..dd214dbb232fb33ced98b5a9a05c1f07e60aa6b0 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/One.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/One.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.toolkit.support.SFunction; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToMany.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToMany.java index f0b19f81b7a5644e2b264b8f112f2837d1316594..eed8b4ac02ad09cae3c139f0d9dbb9954967e701 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToMany.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToMany.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.toolkit.support.SFunction; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOne.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOne.java index 7ac52eadf58a76ea22a30bbb8cac744084514c65..3f6f51866a038c6e2f345b6a1d14ee2e6067e665 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOne.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOne.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOne.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOne.java index 1315ad5f5b9948317bc374c21e4b9c1a3ccff3df..50f359ddb17636a4cb632405753bd1851f2180ac 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOne.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOne.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.toolkit.support.SFunction; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/QueryCondition.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/QueryCondition.java index 769457a7324d77f5f451b571dd310907acb47c8c..8da276e813270fecea9327af90155e9e146fe667 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/QueryCondition.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/QueryCondition.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/annotation/EnableMybatisPlusPlugin.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/annotation/EnableMybatisPlusPlugin.java index a377151fa8b20f483d900543e9345f1bbbec98c1..e6c476282c4df647ceb2597b3b1bfb420138c055 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/annotation/EnableMybatisPlusPlugin.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/annotation/EnableMybatisPlusPlugin.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.annotation; import org.dromara.streamquery.stream.plugin.mybatisplus.engine.configuration.StreamPluginAutoConfiguration; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/configuration/StreamPluginAutoConfiguration.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/configuration/StreamPluginAutoConfiguration.java index 0183fc86dccf5fde400b9629e198dfe6c8ccd447..6ecbb7971db5e4bf6c2f014feed2e6b62414ccf5 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/configuration/StreamPluginAutoConfiguration.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/configuration/StreamPluginAutoConfiguration.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.configuration; import com.baomidou.mybatisplus.core.injector.AbstractMethod; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/constant/PluginConst.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/constant/PluginConst.java index 0c288e6fb3546eb2ebff0e6cc1d007b4ad52d172..3eff4f7c22f1366563594b8bd8ac8adce2d0f396 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/constant/PluginConst.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/constant/PluginConst.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.constant; import org.dromara.streamquery.stream.plugin.mybatisplus.Database; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/enumration/SqlMethodEnum.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/enumration/SqlMethodEnum.java index 799607cc5a77ae57b8086bd2c024f7a0a9859471..c27d2bd023dce8cd7c5dc34fe482293faf6184ad 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/enumration/SqlMethodEnum.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/enumration/SqlMethodEnum.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.enumration; /** @@ -10,8 +26,8 @@ public enum SqlMethodEnum { * 插入 */ SAVE_ONE_SQL("saveOneSql", "插入多条数据(mysql语法批量)", "INSERT INTO %s %s VALUES %s"), - UPDATE_ONE_SQL("updateOneSql", "修改多条数据(mysql语法批量)", "\nUPDATE %s SET %s WHERE %s\n"), - ; + UPDATE_ONE_SQL("updateOneSql", "修改多条数据(mysql语法批量)", "\nUPDATE %s SET %s WHERE %s\n"); + private final String method; private final String desc; private final String sql; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/DynamicMapperHandler.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/DynamicMapperHandler.java index 339f7b99505c8588efbc0390502a48d862d9fe7b..7cbc6b8c6d2d319178bc724894d7404183d61996 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/DynamicMapperHandler.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/DynamicMapperHandler.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.mapper; import com.baomidou.mybatisplus.core.MybatisConfiguration; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/IMapper.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/IMapper.java index ffe248309310a306883db6c3abc72ecd486961e2..4c7a4d3205dcd10ddb3a170bd67da1abced0b630 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/IMapper.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/mapper/IMapper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; @@ -11,8 +27,8 @@ import java.util.Collection; /** * 拓展BaseMapper * + * @param 实体 * @author VampireAchao Cizai_ - */ public interface IMapper extends BaseMapper { diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/MpInjectHelper.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/MpInjectHelper.java index 1130f3d862d1b33ce65c7d88d19bccfc299f2749..8e849dc3fb7b330fb92686ce1966f3f2b04bd4e9 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/MpInjectHelper.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/MpInjectHelper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.methods; import com.baomidou.mybatisplus.annotation.FieldStrategy; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/SaveOneSql.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/SaveOneSql.java index 3cf2a732d94b125217795fd08ee347023a393710..81bf22febf488a30085cde53aeb040836f9f8c41 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/SaveOneSql.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/SaveOneSql.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.methods; import com.baomidou.mybatisplus.annotation.IdType; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/UpdateOneSql.java b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/UpdateOneSql.java index 50cb9a6fde67da69d0a61dab705158f9947875fc..c0baa40c4b8c2061374a132f27742f7548a5ae26 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/UpdateOneSql.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/main/java/org/dromara/streamquery/stream/plugin/mybatisplus/engine/methods/UpdateOneSql.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.engine.methods; import com.baomidou.mybatisplus.core.injector.AbstractMethod; @@ -58,8 +74,8 @@ public class UpdateOneSql extends AbstractMethod implements PluginConst { .filter(i -> !i.isLogicDelete()) .map(i -> i.getColumn() + EQUALS + CASE + SPACE + tableInfo.getKeyColumn() + NEWLINE + SqlScriptUtils.convertForeach(SqlScriptUtils.convertChoose( - MpInjectHelper.updateCondition(i, TableFieldInfo::getUpdateStrategy) - , String.format(WHEN_THEN, safeKeyProperty, SqlScriptUtils.safeParam(ENTITY_DOT + i.getProperty())), + MpInjectHelper.updateCondition(i, TableFieldInfo::getUpdateStrategy), + String.format(WHEN_THEN, safeKeyProperty, SqlScriptUtils.safeParam(ENTITY_DOT + i.getProperty())), String.format(WHEN_THEN, safeKeyProperty, i.getColumn())), COLLECTION_PARAM_NAME, null, ENTITY, null) + END ) diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/CompositiveTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/CompositiveTest.java index bc04ed5816086e660c1b2fc10fe35825fbc39169..cbd02e6b7a999fa8204c683bd496dcff4f541810 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/CompositiveTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/CompositiveTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; /** diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/DatabaseTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/DatabaseTest.java index b82d4b0616b56a80af02e41612ba0a5e7bfeff5c..2912dd25b25d600f7ff041945683cce9f4b86f2d 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/DatabaseTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/DatabaseTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/ManyTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/ManyTest.java index 176f56f521c094383a5c8c0afb450dac045ee471..055e5307f6147f25fcb71ccaa38db9586497c438 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/ManyTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/ManyTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.test.autoconfigure.MybatisPlusTest; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/MybatisPlusTestApplication.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/MybatisPlusTestApplication.java index ebb333548535be3a0e3dd75c379966fc8d6e7f10..d9b87cc45c799cdd472388fed8a5e13a6978239d 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/MybatisPlusTestApplication.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/MybatisPlusTestApplication.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.annotation.DbType; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneTest.java index dd7f17bf100e82c1a8c160d658b56c41384762b6..546f0210e157864ed357b5e0243bfa3e0128bb85 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.test.autoconfigure.MybatisPlusTest; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyTest.java index eee5fc23e9a95157ac5d6489fbdda72404b09010..87d5f9518ba6a5a1963d887acb54933697e5270f 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.test.autoconfigure.MybatisPlusTest; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOneTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOneTest.java index 885033224df3b26042b728b7837ba52e57c5a048..ca6bd8729c00478a1c60d05aa2377700c7c7a15a 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOneTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToManyToOneTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.core.toolkit.Wrappers; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOneTest.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOneTest.java index 30a9e7cf5c61d81eefb2b7bb9a4369368f7bde12..1565fed17a156d348431bc8a55e44c96d2065f75 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOneTest.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/OneToOneTest.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus; import com.baomidou.mybatisplus.test.autoconfigure.MybatisPlusTest; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/mapper/UserInfoMapper.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/mapper/UserInfoMapper.java index bf48c6c3af3910efb62adb2d4b8b07248dd5d664..c235eb2a2d842102e649faea085fa8b206bf5263 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/mapper/UserInfoMapper.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/mapper/UserInfoMapper.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.mapper; import org.apache.ibatis.annotations.Mapper; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/RoleInfo.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/RoleInfo.java index 755f01a112691de7df9844d379b5d0e96172347a..6da6958b67ca4da3ebe846ec40d7971d34de9f11 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/RoleInfo.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/RoleInfo.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.pojo.po; import com.baomidou.mybatisplus.annotation.DbType; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserInfo.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserInfo.java index 8c2345f6f31f1adfbd6408d3985011921db922f9..627410c901c81938a1e71e9c7b92fc728191d6a1 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserInfo.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserInfo.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.pojo.po; import com.baomidou.mybatisplus.annotation.IdType; diff --git a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserRole.java b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserRole.java index ea5db0ff70c6a54fb0e0444bbc8ec2b196e9f03d..bd90f9d376d879e659e260f60b226c4dccccd0d0 100644 --- a/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserRole.java +++ b/stream-plugin/stream-plugin-mybatis-plus/src/test/java/org/dromara/streamquery/stream/plugin/mybatisplus/pojo/po/UserRole.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.dromara.streamquery.stream.plugin.mybatisplus.pojo.po; import lombok.Data;