repo_id stringclasses 875
values | size int64 974 38.9k | file_path stringlengths 10 308 | content stringlengths 974 38.9k |
|---|---|---|---|
apache/rocketmq-clients | 1,124 | java/client/src/main/java/org/apache/rocketmq/client/java/metrics/GaugeObserver.java | /*
* 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.apache.rocketmq.client.java.metrics;
import io.opentelemetry.api.common.Attributes;
import java.util.List;
import java.util.Map;
public interface GaugeObserver {
GaugeObserver EMPTY = new EmptyGaugeObserver();
List<GaugeEnum> getGauges();
Map<Attributes, Double> getValues(GaugeEnum gauge);
}
|
apache/rocketmq-dashboard | 1,138 | src/main/java/org/apache/rocketmq/dashboard/permisssion/Permission.java | /*
* 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.apache.rocketmq.dashboard.permisssion;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Target({ElementType.TYPE, ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface Permission {
}
|
apache/rocketmq-streams | 1,136 | core/src/main/java/org/apache/rocketmq/streams/core/running/Processor.java | package org.apache.rocketmq.streams.core.running;
/*
* 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.
*/
import org.apache.rocketmq.streams.core.exception.RecoverStateStoreThrowable;
public interface Processor<T> {
void addChild(Processor<T> processor);
void preProcess(StreamContext<T> context) throws RecoverStateStoreThrowable;
void process(T data) throws Throwable;
}
|
apache/royale-compiler | 1,102 | compiler/src/main/java/org/apache/royale/compiler/tree/mxml/IMXMLWebServiceOperationArgumentsPropertyNode.java | /*
*
* 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.apache.royale.compiler.tree.mxml;
/**
* AST node for the {@code <arguments>} tag under the {@code <operation>} tag, which is under the {@code <WebService>} tag.
*/
public interface IMXMLWebServiceOperationArgumentsPropertyNode extends IMXMLPropertySpecifierNode
{
}
|
apache/samza | 1,138 | samza-kv/src/main/java/org/apache/samza/storage/kv/LocalTableProviderFactory.java | /*
* 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.apache.samza.storage.kv;
import org.apache.samza.table.TableProvider;
import org.apache.samza.table.TableProviderFactory;
public class LocalTableProviderFactory implements TableProviderFactory {
@Override
public TableProvider getTableProvider(String tableId) {
return new LocalTableProvider(tableId);
}
}
|
apache/seatunnel-web | 1,101 | seatunnel-server/seatunnel-app/src/main/java/org/apache/seatunnel/app/domain/dto/script/CreateScriptDto.java | /*
* 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.apache.seatunnel.app.domain.dto.script;
import lombok.Builder;
import lombok.Data;
@Builder
@Data
public class CreateScriptDto {
private String name;
private byte type;
private int creatorId;
private int menderId;
private byte status;
private String content;
}
|
apache/seatunnel | 1,073 | seatunnel-connectors-v2/connector-easysearch/src/main/java/org/apache/seatunnel/connectors/seatunnel/easysearch/dto/EasysearchClusterInfo.java | /*
* 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.apache.seatunnel.connectors.seatunnel.easysearch.dto;
import lombok.Builder;
import lombok.Getter;
import lombok.ToString;
@Getter
@Builder
@ToString
public class EasysearchClusterInfo {
private String distribution;
private String clusterVersion;
}
|
apache/seatunnel | 1,117 | seatunnel-transforms-v2/src/main/java/org/apache/seatunnel/transform/nlpmodel/llm/remote/Model.java | /*
* 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.apache.seatunnel.transform.nlpmodel.llm.remote;
import org.apache.seatunnel.api.table.type.SeaTunnelRow;
import java.io.Closeable;
import java.io.IOException;
import java.util.List;
public interface Model extends Closeable {
List<String> inference(List<SeaTunnelRow> rows) throws IOException;
}
|
apache/servicecomb-java-chassis | 1,094 | service-registry/registry-etcd/src/main/java/org/apache/servicecomb/registry/etcd/EtcdRegistrationInstance.java | /*
* 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.apache.servicecomb.registry.etcd;
import org.apache.servicecomb.registry.api.RegistrationInstance;
public class EtcdRegistrationInstance extends EtcdInstance implements RegistrationInstance {
public EtcdRegistrationInstance(EtcdInstance instance) {
super(instance);
}
}
|
apache/servicecomb-samples | 1,103 | java-chassis-integration-tests/it-edge/src/main/java/org/apache/servicecomb/it/edge/encrypt/Encrypt.java | /*
* 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.apache.servicecomb.it.edge.encrypt;
import java.util.concurrent.CompletableFuture;
import org.apache.servicecomb.it.authentication.encrypt.Hcr;
public interface Encrypt {
CompletableFuture<String> queryUserId(String serviceToken);
CompletableFuture<Hcr> queryHcr(String hcrId);
}
|
apache/servicecomb-toolkit | 1,072 | oas-validator/oas-validator-core/src/main/java/org/apache/servicecomb/toolkit/oasv/diffvalidation/factory/MediaTypeDiffValidatorFactory.java | /*
* 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.apache.servicecomb.toolkit.oasv.diffvalidation.factory;
import org.apache.servicecomb.toolkit.oasv.diffvalidation.api.MediaTypeDiffValidator;
public interface MediaTypeDiffValidatorFactory extends OasObjectDiffValidatorFactory<MediaTypeDiffValidator> {
}
|
apache/servicecomb-toolkit | 1,072 | oas-validator/oas-validator-core/src/main/java/org/apache/servicecomb/toolkit/oasv/diffvalidation/factory/OperationDiffValidatorFactory.java | /*
* 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.apache.servicecomb.toolkit.oasv.diffvalidation.factory;
import org.apache.servicecomb.toolkit.oasv.diffvalidation.api.OperationDiffValidator;
public interface OperationDiffValidatorFactory extends OasObjectDiffValidatorFactory<OperationDiffValidator> {
}
|
apache/servicecomb-toolkit | 1,072 | oas-validator/oas-validator-core/src/main/java/org/apache/servicecomb/toolkit/oasv/diffvalidation/factory/ParameterDiffValidatorFactory.java | /*
* 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.apache.servicecomb.toolkit.oasv.diffvalidation.factory;
import org.apache.servicecomb.toolkit.oasv.diffvalidation.api.ParameterDiffValidator;
public interface ParameterDiffValidatorFactory extends OasObjectDiffValidatorFactory<ParameterDiffValidator> {
}
|
apache/servicecomb-toolkit | 1,072 | oas-validator/oas-validator-core/src/main/java/org/apache/servicecomb/toolkit/oasv/diffvalidation/factory/ResponsesDiffValidatorFactory.java | /*
* 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.apache.servicecomb.toolkit.oasv.diffvalidation.factory;
import org.apache.servicecomb.toolkit.oasv.diffvalidation.api.ResponsesDiffValidator;
public interface ResponsesDiffValidatorFactory extends OasObjectDiffValidatorFactory<ResponsesDiffValidator> {
}
|
apache/shardingsphere | 1,101 | parser/sql/spi/src/main/java/org/apache/shardingsphere/sql/parser/api/visitor/statement/SQLStatementVisitor.java | /*
* 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.apache.shardingsphere.sql.parser.api.visitor.statement;
import org.apache.shardingsphere.sql.parser.api.ASTNode;
import org.apache.shardingsphere.sql.parser.api.visitor.SQLVisitor;
/**
* SQL statement visitor.
*/
public interface SQLStatementVisitor extends SQLVisitor<ASTNode> {
}
|
apache/shardingsphere | 1,104 | kernel/authority/core/src/main/java/org/apache/shardingsphere/authority/constant/AuthorityConstants.java | /*
* 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.apache.shardingsphere.authority.constant;
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
/**
* Authority constants.
*/
@NoArgsConstructor(access = AccessLevel.PRIVATE)
public final class AuthorityConstants {
public static final String PRIVILEGE_WILDCARD = "*";
}
|
apache/shardingsphere | 1,111 | features/encrypt/core/src/main/java/org/apache/shardingsphere/encrypt/constant/EncryptOrder.java | /*
* 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.apache.shardingsphere.encrypt.constant;
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
/**
* Encrypt order.
*/
@NoArgsConstructor(access = AccessLevel.PRIVATE)
public final class EncryptOrder {
/**
* Encrypt order.
*/
public static final int ORDER = 10;
}
|
apache/shenyu | 1,134 | shenyu-admin/src/test/java/org/apache/shenyu/admin/model/vo/PluginHandleVOTest.java | /*
* 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.apache.shenyu.admin.model.vo;
import org.apache.shenyu.admin.AbstractReflectGetterSetterTest;
/**
* Test case for PluginHandleVO.
*/
public final class PluginHandleVOTest extends AbstractReflectGetterSetterTest {
@Override
protected Class<?> getTargetClass() {
return PluginHandleVO.class;
}
}
|
apache/sis | 1,136 | endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/services/package-info.java | /*
* 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.
*/
/**
* Exposes some storage functionalities as service providers.
* This package is not for implementations of {@link org.apache.sis.storage.DataStoreProvider},
* but rather for services defined by other SIS module or by the Java platform.
*
* @author Martin Desruisseaux (Geomatys)
*/
package org.apache.sis.storage.services;
|
apache/skywalking-java | 1,054 | test/plugin/scenarios/shardingsphere-3.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/shardingsphere/service/api/repository/OrderItemRepository.java | /*
* 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.apache.skywalking.apm.testcase.shardingsphere.service.api.repository;
import org.apache.skywalking.apm.testcase.shardingsphere.service.api.entity.OrderItem;
public interface OrderItemRepository extends CommonRepository<OrderItem> {
}
|
apache/skywalking-java | 1,054 | test/plugin/scenarios/shardingsphere-4.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/shardingsphere/service/api/repository/OrderItemRepository.java | /*
* 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.apache.skywalking.apm.testcase.shardingsphere.service.api.repository;
import org.apache.skywalking.apm.testcase.shardingsphere.service.api.entity.OrderItem;
public interface OrderItemRepository extends CommonRepository<OrderItem> {
}
|
apache/skywalking-java | 1,072 | test/plugin/scenarios/spring-3.0.x-scenario/src/main/java/test/apache/skywalking/apm/testcase/spring3/component/TestComponentBean.java | /*
* 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 test.apache.skywalking.apm.testcase.spring3.component;
import org.springframework.stereotype.Component;
@Component
public class TestComponentBean {
public String componentMethod(String name) {
return name + "-" + "dealWith-component";
}
}
|
apache/skywalking-java | 1,072 | test/plugin/scenarios/spring-3.1.x-scenario/src/main/java/test/apache/skywalking/apm/testcase/spring3/component/TestComponentBean.java | /*
* 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 test.apache.skywalking.apm.testcase.spring3.component;
import org.springframework.stereotype.Component;
@Component
public class TestComponentBean {
public String componentMethod(String name) {
return name + "-" + "dealWith-component";
}
}
|
apache/skywalking-java | 1,072 | test/plugin/scenarios/spring-4.1.x-scenario/src/main/java/test/apache/skywalking/apm/testcase/spring3/component/TestComponentBean.java | /*
* 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 test.apache.skywalking.apm.testcase.spring3.component;
import org.springframework.stereotype.Component;
@Component
public class TestComponentBean {
public String componentMethod(String name) {
return name + "-" + "dealWith-component";
}
}
|
apache/skywalking-java | 1,072 | test/plugin/scenarios/spring-4.3.x-scenario/src/main/java/test/apache/skywalking/apm/testcase/spring3/component/TestComponentBean.java | /*
* 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 test.apache.skywalking.apm.testcase.spring3.component;
import org.springframework.stereotype.Component;
@Component
public class TestComponentBean {
public String componentMethod(String name) {
return name + "-" + "dealWith-component";
}
}
|
apache/skywalking-java | 1,077 | test/plugin/scenarios/nats-2.14.x-2.16.5-scenario/src/main/java/org/apache/skywalking/apm/testcase/nats/client/work/StopSignal.java | /*
* 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.apache.skywalking.apm.testcase.nats.client.work;
public class StopSignal {
private volatile int stop = 1;
public void stop() {
this.stop = 0;
}
public boolean stopped() {
return this.stop == 0;
}
}
|
apache/skywalking-java | 1,123 | test/e2e/base/consumer/src/main/java/org/apache/skywalking/e2e/E2EConfiguration.java | /*
* 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.apache.skywalking.e2e;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
@Data
@Configuration
@ConfigurationProperties("e2e")
public class E2EConfiguration {
private String providerBaseUrl;
}
|
apache/skywalking | 1,096 | oap-server/oal-rt/src/main/java/org/apache/skywalking/oap/server/core/source/oal/rt/metrics/MetricClassPackageHolder.java | /*
* 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.apache.skywalking.oap.server.core.source.oal.rt.metrics;
/**
* MetricClassPackageHolder holds the package for generated metric classes.
*
* @since 8.9.0 for adopting JDK16+ to avoid `--add-opens java.base/java.lang=ALL-UNNAMED`
*/
public class MetricClassPackageHolder {
}
|
apache/skywalking | 1,109 | oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/query/type/TopNRecord.java | /*
* 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.apache.skywalking.oap.server.core.query.type;
import lombok.Getter;
import lombok.Setter;
/**
* @since 8.0.0 replaced by {@link SelectedRecord}
*/
@Deprecated
@Setter
@Getter
public class TopNRecord {
private String statement;
private long latency;
private String traceId;
}
|
apache/synapse | 1,123 | modules/core/src/main/java/org/apache/synapse/mediators/eip/sample/MessageQueue.java | /*
* 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.apache.synapse.mediators.eip.sample;
import org.apache.synapse.MessageContext;
/**
*
*/
public interface MessageQueue {
void add(MessageContext synCtx);
MessageContext get();
boolean isEmpty();
boolean isPersistent();
boolean persist();
void load();
}
|
apache/synapse | 1,126 | modules/core/src/main/java/org/apache/synapse/config/xml/endpoints/DefinitionFactory.java | /*
* Copyright 2004,2005 The Apache Software Foundation.
*
* Licensed 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.apache.synapse.config.xml.endpoints;
import org.apache.axiom.om.OMElement;
import org.apache.synapse.endpoints.EndpointDefinition;
public interface DefinitionFactory {
/**
* This method should extract the QoS information from the XML infoset which represents an
* endpoint
*
* @param elem XML which represents the endpoint with QoS information
* @return the created endpoint definition
*/
public EndpointDefinition createDefinition(OMElement elem);
}
|
apache/systemds | 1,144 | src/main/java/org/apache/sysds/lops/LopsException.java | /*
* 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.apache.sysds.lops;
import org.apache.sysds.api.DMLException;
public class LopsException extends DMLException
{
private static final long serialVersionUID = 1L;
public LopsException(String message)
{
super(message);
}
public LopsException(String message, Throwable cause) {
super(message, cause);
}
}
|
apache/tajo | 1,117 | tajo-storage/tajo-storage-common/src/main/java/org/apache/tajo/storage/annotation/ForSplitableStore.java | /**
* 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.apache.tajo.storage.annotation;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
public @interface ForSplitableStore {
}
|
apache/tapestry-5 | 1,100 | tapestry-core/src/main/java/org/apache/tapestry5/internal/services/assets/CompressionAnalyzerImpl.java | package org.apache.tapestry5.internal.services.assets;
import java.util.Map;
import org.apache.tapestry5.http.services.CompressionAnalyzer;
public class CompressionAnalyzerImpl implements CompressionAnalyzer
{
private final Map<String, Boolean> configuration;
public CompressionAnalyzerImpl(Map<String, Boolean> configuration)
{
this.configuration = configuration;
}
public boolean isCompressable(String contentType)
{
if (contentType == null) {
throw new IllegalStateException("Content type provided to CompressionAnalyzer is null, which is not allowed.");
}
int x = contentType.indexOf(';');
String key = x < 0 ? contentType : contentType.substring(0, x);
Boolean result = configuration.get(key);
if (result != null) {
return result;
}
// Now look for a wild card.
x = contentType.indexOf('/');
String wildKey = contentType.substring(0, x) + "/*";
result = configuration.get(wildKey);
return result == null ? true : result;
}
}
|
apache/tapestry-5 | 1,112 | tapestry-core/src/test/java/org/apache/tapestry5/internal/transform/pages/StateHolder.java | // Copyright 2007, 2008, 2011 The Apache Software Foundation
//
// Licensed 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.apache.tapestry5.internal.transform.pages;
import org.apache.tapestry5.annotations.SessionState;
import org.apache.tapestry5.internal.services.SimpleASO;
public class StateHolder
{
@SessionState
private SimpleASO bean;
private boolean beanExists;
public SimpleASO getBean()
{
return bean;
}
public void setBean(SimpleASO bean)
{
this.bean = bean;
}
public boolean getBeanExists()
{
return beanExists;
}
}
|
apache/tapestry-5 | 1,117 | tapestry-cdi/src/test/java/org/apache/tapestry5/cdi/test/beans/ws/HelloWorldService.java | // Copyright 2013 The Apache Software Foundation
//
// Licensed 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.apache.tapestry5.cdi.test.beans.ws;
import javax.ejb.Local;
import javax.jws.WebService;
@WebService(targetNamespace = "https://github.com/apache/tapestry-5/")
@Local
public interface HelloWorldService {
/**
* Say hello as a response
*
* @return A simple hello world message
*/
public String sayHello();
/**
* Say hello to someone
*
* @param name The name of the person to say hello to
*/
public String sayHelloToName(String name);
}
|
apache/teaclave-java-tee-sdk | 1,127 | sdk/enclave/src/test/java/org/apache/teaclave/javasdk/enclave/TestTarget.java | // 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.apache.teaclave.javasdk.enclave;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
public @interface TestTarget {
Class<?> value();
}
|
apache/tinkerpop | 1,109 | gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/remote/traversal/DefaultRemoteTraverser.java | /*
* 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.apache.tinkerpop.gremlin.process.remote.traversal;
/**
* @author Stephen Mallette (http://stephen.genoprime.com)
*/
public class DefaultRemoteTraverser<T> extends AbstractRemoteTraverser<T> {
public DefaultRemoteTraverser(final T t, final long bulk) {
super(t, bulk);
}
}
|
apache/tomee | 1,108 | itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/stateful/BasicStatefulInterceptedLocal.java | /**
* 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.apache.openejb.test.stateful;
import java.util.Map;
/**
* @version $Rev$ $Date$
*/
public interface BasicStatefulInterceptedLocal {
public String reverse(String str);
public String concat(String str1, String str2);
public Map<String, Object> getContextData();
}
|
apache/wicket | 1,129 | wicket-examples/src/main/java/org/apache/wicket/examples/authentication3/AdminPage.java | /*
* 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.apache.wicket.examples.authentication3;
import org.apache.wicket.authroles.authorization.strategies.role.annotations.AuthorizeInstantiation;
/**
* A page only accessible by a user in the ADMIN role.
*
* @author Jonathan Locke
*/
@AuthorizeInstantiation("ADMIN")
public class AdminPage extends BasePage
{
}
|
apache/xmlbeans | 1,150 | src/test/java/xmlobject/xmlloader/detailed/XmlLoaderBvtTest.java | /* Copyright 2004 The Apache Software Foundation
*
* Licensed 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 xmlobject.xmlloader.detailed;
import org.junit.jupiter.api.Test;
import org.tranxml.tranXML.version40.CarLocationMessageDocument;
import xmlcursor.common.Common;
import static org.junit.jupiter.api.Assertions.assertNotNull;
import static xmlcursor.common.BasicCursorTestCase.jobj;
public class XmlLoaderBvtTest {
@Test
void testCastDocument() throws Exception {
CarLocationMessageDocument clm = (CarLocationMessageDocument) jobj(Common.TRANXML_FILE_CLM);
assertNotNull(clm);
}
}
|
apache/xmlgraphics-fop | 1,145 | fop-core/src/main/java/org/apache/fop/pdf/StructureType.java | /*
* 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.
*/
/* $Id$ */
package org.apache.fop.pdf;
/**
* A structure type, as defined in Section 10.6.2 of the PDF Reference, fourth edition (PDF 1.5).
*/
public interface StructureType {
/**
* Returns the name of this structure type.
*
* @return the name object identifying this structure type
*/
PDFName getName();
}
|
apache/zookeeper | 1,133 | zookeeper-server/src/main/java/org/apache/zookeeper/server/metric/Metric.java | /*
* 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.apache.zookeeper.server.metric;
import java.util.Map;
public abstract class Metric {
public void add(long value) {
}
public void add(int key, long value) {
}
public void add(String key, long value) {
}
public void reset() {
}
public abstract Map<String, Object> values();
}
|
apache/zookeeper | 1,142 | zookeeper-server/src/main/java/org/apache/zookeeper/DigestWatcher.java | /*
* 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.apache.zookeeper;
/**
* This interface is used to notify the digest mismatch event.
*/
public interface DigestWatcher {
/**
* Called when the digest mismatch is found on a given zxid.
*
* @param mismatchZxid the zxid when the digest mismatch happened.
*/
void process(long mismatchZxid);
}
|
google/android-classyshark | 1,124 | ClassySharkWS/src/com/google/classyshark/gui/theme/light/LightColorScheme.java | /*
* Copyright 2015 Google, Inc.
*
* Licensed 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 com.google.classyshark.gui.theme.light;
import java.awt.Color;
/**
* Application color scheme
*/
class LightColorScheme {
private LightColorScheme(){}
static final Color DEFAULT = new Color(101, 123, 131);
static final Color KEYWORDS = new Color(181, 137, 0);
static final Color IDENTIFIERS = new Color(133, 153, 0);
static final Color ANNOTATIONS = new Color(108, 113, 196);
static final Color SELECTION_BG = new Color(7, 56, 66);
static final Color NAMES = new Color(147, 161, 161);
}
|
google/auto | 1,150 | factory/src/test/resources/good/ConstructorAnnotatedNonFinal.java | /*
* Copyright 2013 Google LLC
*
* Licensed 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 tests;
import com.google.auto.factory.AutoFactory;
import com.google.auto.factory.Provided;
final class ConstructorAnnotatedNonFinal {
@AutoFactory(allowSubclasses = true)
ConstructorAnnotatedNonFinal() {}
ConstructorAnnotatedNonFinal(Object obj) {}
@AutoFactory(allowSubclasses = true)
ConstructorAnnotatedNonFinal(String s) {}
@AutoFactory(allowSubclasses = true)
ConstructorAnnotatedNonFinal(@Provided Object obj, int i) {}
@AutoFactory(allowSubclasses = true)
ConstructorAnnotatedNonFinal(@Provided Object obj, char c) {}
}
|
google/bindiff | 1,121 | java/ui/src/main/java/com/google/security/zynamics/bindiff/project/WorkspaceListener.java | // Copyright 2011-2024 Google LLC
//
// Licensed 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
//
// https://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 com.google.security.zynamics.bindiff.project;
import com.google.security.zynamics.bindiff.project.diff.Diff;
/** Listener interface for workspace events. */
public interface WorkspaceListener {
default void addedDiff(final Diff diff) {
// Do nothing by default
}
default void closedWorkspace() {
// Do nothing by default
}
default void loadedWorkspace(final Workspace workspace) {
// Do nothing by default
}
default void removedDiff(final Diff diff) {
// Do nothing by default
}
}
|
google/gdata-java-client | 1,133 | java/src/com/google/gdata/wireformats/ContentModelException.java | /* Copyright (c) 2008 Google Inc.
*
* Licensed 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 com.google.gdata.wireformats;
import com.google.gdata.util.ServiceException;
/**
* The ContentModelException indicates that a content model
* is incompatible with request content being generated or
* parsed.
*/
public class ContentModelException extends ServiceException {
public ContentModelException(String message) {
super(message);
}
public ContentModelException(String message, Throwable cause) {
super(message, cause);
}
public ContentModelException(Throwable cause) {
super(cause);
}
}
|
google/gdata-java-client | 1,148 | java/src/com/google/gdata/data/media/IMediaEntry.java | /* Copyright (c) 2008 Google Inc.
*
* Licensed 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 com.google.gdata.data.media;
import com.google.gdata.data.IEntry;
/**
* The IMediaEntry interface defines a common base interface for GData media
* entries that is shared between the old and new data models.
*/
public interface IMediaEntry extends IEntry {
/**
* Returns the {@link MediaSource} that contains the media data for the entry.
*/
public MediaSource getMediaSource();
/**
* Sets the {@link MediaSource} that contains the media data for the entry.
*/
public void setMediaSource(MediaSource source);
}
|
google/guava | 1,158 | guava/src/com/google/common/collect/IgnoreJRERequirement.java | /*
* Copyright 2019 The Guava Authors
*
* Licensed 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 com.google.common.collect;
import static java.lang.annotation.ElementType.CONSTRUCTOR;
import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.ElementType.TYPE;
import java.lang.annotation.Target;
/**
* Disables Animal Sniffer's checking of compatibility with older versions of Java/Android.
*
* <p>Each package's copy of this annotation needs to be listed in our {@code pom.xml}.
*/
@Target({METHOD, CONSTRUCTOR, TYPE, FIELD})
@interface IgnoreJRERequirement {}
|
google/guava | 1,158 | guava/src/com/google/common/reflect/IgnoreJRERequirement.java | /*
* Copyright 2019 The Guava Authors
*
* Licensed 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 com.google.common.reflect;
import static java.lang.annotation.ElementType.CONSTRUCTOR;
import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.ElementType.TYPE;
import java.lang.annotation.Target;
/**
* Disables Animal Sniffer's checking of compatibility with older versions of Java/Android.
*
* <p>Each package's copy of this annotation needs to be listed in our {@code pom.xml}.
*/
@Target({METHOD, CONSTRUCTOR, TYPE, FIELD})
@interface IgnoreJRERequirement {}
|
google/j2cl | 1,132 | transpiler/javatests/com/google/j2cl/integration/java/narrowingdoubletofloat/Main.java | /*
* Copyright 2021 Google Inc.
*
* Licensed 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
*
* https://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 narrowingdoubletofloat;
import static com.google.j2cl.integration.testing.Asserts.assertTrue;
public class Main {
public static void main(String... args) {
testCoercions();
}
private static void testCoercions() {
double dd = 2415919103.7; // dd < Double.MAX_VALUE;
double md = 1.7976931348623157E308; // Double.MAX_VALUE;
assertTrue(((float) dd == dd)); // we don't honor float-double precision differences
assertTrue(((float) md == md)); // we don't honor float-double precision differences
}
}
|
google/j2cl | 1,132 | transpiler/javatests/com/google/j2cl/readable/java/j2kt/LateInitTest.java | /*
* Copyright 2023 Google Inc.
*
* Licensed 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
*
* https://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 j2kt;
import static org.junit.Assert.assertEquals;
import org.jspecify.annotations.NullMarked;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.JUnit4;
@RunWith(JUnit4.class)
@NullMarked
public final class LateInitTest {
private String uninitialized;
@Before
public void setup() {
uninitialized = "I have been initialized";
}
@Test
public void behaviorBeingTested_expectedResult() {
assertEquals(uninitialized, "I have been initialized");
}
}
|
google/j2objc | 1,116 | jre_emul/android/platform/external/icu/android_icu4j/src/main/tests/android/icu/dev/test/util/Equator.java | /* GENERATED SOURCE. DO NOT MODIFY. */
// © 2016 and later: Unicode, Inc. and others.
// License & terms of use: http://www.unicode.org/copyright.html#License
/*
*******************************************************************************
* Copyright (C) 2002-2004, International Business Machines Corporation and *
* others. All Rights Reserved. *
*******************************************************************************
*/
package android.icu.dev.test.util;
public interface Equator {
/**
* Comparator function. If overridden, must handle case of null,
* and compare any two objects that could be compared.
* Must obey normal rules of symmetry: a=b => b=a
* and transitivity: a=b & b=c => a=b)
* @param a
* @param b
* @return true if a and b are equal
*/
public boolean isEqual(Object a, Object b);
/**
* Must obey normal rules: a=b => getHashCode(a)=getHashCode(b)
* @param object
* @return a hash code for the object
*/
public int getHashCode(Object object);
} |
google/jimfs | 1,139 | jimfs/src/test/java/com/google/common/jimfs/BasicFileAttribute.java | /*
* Copyright 2013 Google Inc.
*
* Licensed 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 com.google.common.jimfs;
import static com.google.common.base.Preconditions.checkNotNull;
import java.nio.file.attribute.FileAttribute;
/** @author Colin Decker */
public class BasicFileAttribute<T> implements FileAttribute<T> {
private final String name;
private final T value;
public BasicFileAttribute(String name, T value) {
this.name = checkNotNull(name);
this.value = checkNotNull(value);
}
@Override
public String name() {
return name;
}
@Override
public T value() {
return value;
}
}
|
google/mail-importer | 1,147 | src/main/java/to/lean/tools/gmail/importer/gmail/User.java | /*
* Copyright 2015 The Mail Importer Authors. All rights reserved.
*
* Licensed 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 to.lean.tools.gmail.importer.gmail;
import com.google.auto.value.AutoValue;
import com.google.common.base.Charsets;
import java.util.Base64;
/** Encapsulates information about the user in a type safe way. */
@AutoValue
abstract class User {
static User create(String emailAddress) {
return new AutoValue_User(emailAddress);
}
abstract String getEmailAddress();
String getEmailAddressAsKey() {
return Base64.getEncoder().encodeToString(getEmailAddress().getBytes(Charsets.UTF_8));
}
}
|
google/tsunami-security-scanner-plugins | 1,035 | google/detectors/rce/cve20179805/src/main/java/com/google/tsunami/plugins/detectors/rce/cve20179805/ApacheStrutsInsecureDeserializeDetectorBootstrapModule.java | /*
* Copyright 2020 Google LLC
*
* Licensed 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 com.google.tsunami.plugins.detectors.rce.cve20179805;
import com.google.tsunami.plugin.PluginBootstrapModule;
/** A {@link PluginBootstrapModule} for {@link ApacheStrutsInsecureDeserializeDetector}. */
public final class ApacheStrutsInsecureDeserializeDetectorBootstrapModule
extends PluginBootstrapModule {
@Override
protected void configurePlugin() {
registerPlugin(ApacheStrutsInsecureDeserializeDetector.class);
}
}
|
googlearchive/gwt-google-apis | 1,092 | apis/samples/urlshortener/com/google/api/gwt/samples/urlshortener/shared/UrlshortenerAuthScope.java | /*
* Copyright 2011 Google Inc.
*
* Licensed 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 com.google.api.gwt.samples.urlshortener.shared;
import com.google.api.gwt.shared.AuthScope;
/**
* Auth scopes available to the urlshortener service.
*
* @author jasonhall@google.com (Jason Hall)
*/
public enum UrlshortenerAuthScope implements AuthScope {
URLSHORTENER("https://www.googleapis.com/auth/urlshortener"),
;
private final String url;
private UrlshortenerAuthScope(String url) {
this.url = url;
}
@Override
public String getScope() {
return url;
}
}
|
googlefonts/sfntly | 1,120 | java/src/com/google/typography/font/sfntly/table/opentype/component/VisibleSubTable.java | package com.google.typography.font.sfntly.table.opentype.component;
import com.google.typography.font.sfntly.data.ReadableFontData;
import com.google.typography.font.sfntly.data.WritableFontData;
import com.google.typography.font.sfntly.table.SubTable;
public abstract class VisibleSubTable extends SubTable {
private VisibleSubTable(ReadableFontData data) {
super(data);
}
public abstract static class Builder<T extends SubTable> extends SubTable.Builder<T> {
protected int serializedLength;
protected Builder() {
super(null);
}
protected Builder(ReadableFontData data) {
super(data);
}
@Override
public abstract int subSerialize(WritableFontData newData);
/**
* Even though public, not to be used by the end users. Made public only
* make it available to packages under
* {@code com.google.typography.font.sfntly.table.opentype}.
*/
@Override
public abstract int subDataSizeToSerialize();
@Override
protected abstract void subDataSet();
@Override
protected abstract T subBuildTable(ReadableFontData data);
}
} |
hibernate/hibernate-orm | 1,056 | hibernate-core/src/test/java/org/hibernate/orm/test/annotations/cascade/multicircle/nonjpa/sequence/C.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.orm.test.annotations.cascade.multicircle.nonjpa.sequence;
import java.util.Set;
/**
* No Documentation
*/
@jakarta.persistence.Entity
public class C extends AbstractEntity {
private static final long serialVersionUID = 1226955752L;
@jakarta.persistence.OneToMany(mappedBy = "c")
private Set<B> bCollection = new java.util.HashSet<B>();
@jakarta.persistence.OneToMany(mappedBy = "c")
@org.hibernate.annotations.Cascade({
org.hibernate.annotations.CascadeType.PERSIST,
org.hibernate.annotations.CascadeType.MERGE,
org.hibernate.annotations.CascadeType.REFRESH
})
private Set<D> dCollection = new java.util.HashSet<D>();
public Set<B> getBCollection() {
return bCollection;
}
public void setBCollection(Set<B> bCollection) {
this.bCollection = bCollection;
}
public Set<D> getDCollection() {
return dCollection;
}
public void setDCollection(Set<D> dCollection) {
this.dCollection = dCollection;
}
}
|
hibernate/hibernate-orm | 1,058 | hibernate-core/src/test/java/org/hibernate/orm/test/jpa/callbacks/xml/replace/Product.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.orm.test.jpa.callbacks.xml.replace;
import org.hibernate.orm.test.jpa.callbacks.xml.common.CallbackTarget;
import jakarta.persistence.Entity;
import jakarta.persistence.EntityListeners;
import jakarta.persistence.Id;
/**
* @author Steve Ebersole
*/
@Entity
@EntityListeners({ ListenerC.class, ListenerB.class})
public class Product extends CallbackTarget {
@Id
private Integer id;
private String partNumber;
private double cost;
public Product() {
}
public Product(Integer id, String partNumber, double cost) {
this.id = id;
this.partNumber = partNumber;
this.cost = cost;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getPartNumber() {
return partNumber;
}
public void setPartNumber(String partNumber) {
this.partNumber = partNumber;
}
public double getCost() {
return cost;
}
public void setCost(double cost) {
this.cost = cost;
}
}
|
hibernate/hibernate-orm | 1,059 | hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/temptable/SingleStoreLocalTemporaryTableStrategy.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.community.dialect.temptable;
import org.hibernate.dialect.temptable.StandardLocalTemporaryTableStrategy;
import org.hibernate.query.sqm.mutation.spi.AfterUseAction;
/**
* SingleStore specific local temporary table strategy.
*/
public class SingleStoreLocalTemporaryTableStrategy extends StandardLocalTemporaryTableStrategy {
public static final SingleStoreLocalTemporaryTableStrategy INSTANCE = new SingleStoreLocalTemporaryTableStrategy();
@Override
public String getTemporaryTableCreateCommand() {
return "create temporary table if not exists";
}
//SingleStore throws an error on drop temporary table if there are uncommited statements within transaction.
//Just 'drop table' statement causes implicit commit, so using 'delete from'.
@Override
public String getTemporaryTableDropCommand() {
return "delete from";
}
@Override
public AfterUseAction getTemporaryTableAfterUseAction() {
return AfterUseAction.DROP;
}
}
|
hibernate/hibernate-orm | 1,068 | hibernate-core/src/test/java/org/hibernate/orm/test/annotations/id/sequences/entities/Dog.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.orm.test.annotations.id.sequences.entities;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.Table;
import jakarta.persistence.TableGenerator;
/**
* Share the generator table decribed by the GEN_TABLE GeneratedIdTable
* using the Dog key as discriminator
*
* @author Emmanuel Bernard
*/
@Entity
@Table(name = "tbl_dog")
@TableGenerator(name = "DogGen", table = "GENERATOR_TABLE", pkColumnName = "pkey",
valueColumnName = "hi", pkColumnValue = "Dog", allocationSize = 10)
public class Dog {
private Integer id;
private String name;
@Id
@GeneratedValue(strategy = GenerationType.TABLE, generator = "DogGen")
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
}
|
hibernate/hibernate-orm | 1,076 | tooling/metamodel-generator/src/test/java/org/hibernate/processor/test/sortedcollection/SortedCollectionTest.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.processor.test.sortedcollection;
import org.hibernate.processor.test.util.CompilationTest;
import org.hibernate.processor.test.util.TestForIssue;
import org.hibernate.processor.test.util.WithClasses;
import org.junit.jupiter.api.Test;
import static org.hibernate.processor.test.util.TestUtil.assertMetamodelClassGeneratedFor;
import static org.hibernate.processor.test.util.TestUtil.assertPresenceOfFieldInMetamodelFor;
/**
* @author Hardy Ferentschik
*/
@CompilationTest
class SortedCollectionTest {
@Test
@TestForIssue(jiraKey = "METAGEN-62")
@WithClasses({ Printer.class, PrintJob.class })
void testGenerics() {
assertMetamodelClassGeneratedFor( Printer.class );
assertMetamodelClassGeneratedFor( PrintJob.class );
assertPresenceOfFieldInMetamodelFor( Printer.class, "printQueue", "There sorted set attribute is missing" );
assertPresenceOfFieldInMetamodelFor( Printer.class, "printedJobs", "There sorted map attribute is missing" );
}
}
|
hibernate/hibernate-orm | 1,086 | hibernate-core/src/main/java/org/hibernate/bytecode/enhance/spi/UnsupportedEnhancementStrategy.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.bytecode.enhance.spi;
import org.hibernate.Incubating;
/**
* The expected behavior when encountering a class that cannot be enhanced,
* in particular when attribute names don't match field names.
*
* @see org.hibernate.bytecode.enhance.spi.EnhancementContext#getUnsupportedEnhancementStrategy
*/
@Incubating
public enum UnsupportedEnhancementStrategy {
/**
* When a class cannot be enhanced, skip enhancement for that class only.
*/
SKIP,
/**
* When a class cannot be enhanced, throw an exception with an actionable message.
*/
FAIL,
/**
* Legacy behavior: when a class cannot be enhanced, ignore that fact and try to enhance it anyway.
* <p>
* <strong>This is utterly unsafe and may cause errors, unpredictable behavior, and data loss.</strong>
* <p>
* Intended only for internal use in contexts with rigid backwards compatibility requirements.
*
* @deprecated Use {@link #SKIP} or {@link #FAIL} instead.
*/
@Deprecated
LEGACY
}
|
hibernate/hibernate-orm | 1,094 | hibernate-core/src/main/java/org/hibernate/property/access/spi/PropertyAccessStrategyResolver.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.property.access.spi;
import org.hibernate.metamodel.RepresentationMode;
import org.hibernate.service.Service;
/**
* Contract for resolving the {@link PropertyAccessStrategy} to use.
*
* @author Steve Ebersole
*/
//TODO: moving forward I'd prefer this not be a service, but instead a
// strategy on the MetadataBuildingContext or MetadataBuildingOptions
public interface PropertyAccessStrategyResolver extends Service {
/**
* Resolve the PropertyAccessStrategy to use
*
* @param containerClass The java class of the entity
* @param explicitAccessStrategyName The access strategy name explicitly specified, if any.
* @param representationMode The entity mode in effect for the property, used to interpret different default strategies.
*
* @return The resolved PropertyAccessStrategy
*/
PropertyAccessStrategy resolvePropertyAccessStrategy(
Class<?> containerClass,
String explicitAccessStrategyName,
RepresentationMode representationMode);
}
|
hibernate/hibernate-orm | 1,122 | hibernate-core/src/test/java/org/hibernate/orm/test/cdi/general/hibernatesearch/package-info.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
/**
* Package for testing requests of CDI beans in Hibernate Search.
*
* In Hibernate Search,
* beans are retrieved directly from the {@link org.hibernate.resource.beans.container.spi.BeanContainer}
* because Hibernate Search is not bound by the JPA spec
* and wants to leave the lifecycle of beans up to CDI instead
* of controlling it in {@link org.hibernate.resource.beans.spi.ManagedBeanRegistry}.
* This involves using {@code canUseCachedReferences = false} and {@code useJpaCompliantCreation = false}
* in {@link org.hibernate.resource.beans.container.spi.BeanContainer.LifecycleOptions}).
*
* Mainly these are regression tests against Hibernate Search's pattern of usage of ORM's
* {@link org.hibernate.resource.beans.container.spi.BeanContainer} as accessed
* via {@link org.hibernate.resource.beans.spi.ManagedBeanRegistry#getBeanContainer()}.
*
* @see org.hibernate.orm.test.cdi.general.hibernatesearch.HibernateSearchSimulatedIntegrator
*/
package org.hibernate.orm.test.cdi.general.hibernatesearch;
|
hibernate/hibernate-reactive | 1,091 | hibernate-reactive-core/src/main/java/org/hibernate/reactive/loader/ast/spi/ReactiveMultiIdEntityLoader.java | /* Hibernate, Relational Persistence for Idiomatic Java
*
* SPDX-License-Identifier: Apache-2.0
* Copyright: Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.reactive.loader.ast.spi;
import java.util.List;
import java.util.concurrent.CompletionStage;
import org.hibernate.engine.spi.SharedSessionContractImplementor;
import org.hibernate.loader.ast.spi.MultiIdEntityLoader;
import org.hibernate.loader.ast.spi.MultiIdLoadOptions;
import org.hibernate.reactive.logging.impl.Log;
import static java.lang.invoke.MethodHandles.lookup;
import static org.hibernate.reactive.logging.impl.LoggerFactory.make;
/**
* @see org.hibernate.loader.ast.spi.MultiIdEntityLoader
*/
public interface ReactiveMultiIdEntityLoader<T> extends MultiIdEntityLoader<T> {
@Override
default <K> List<T> load(K[] ids, MultiIdLoadOptions options, SharedSessionContractImplementor session) {
throw make( Log.class, lookup() ).nonReactiveMethodCall( "reactiveLoad" );
}
<K> CompletionStage<List<T>> reactiveLoad(K[] ids, MultiIdLoadOptions options, SharedSessionContractImplementor session);
}
|
hibernate/hibernate-search | 1,024 | integrationtest/mapper/pojo-base/src/test/java/org/hibernate/search/integrationtest/mapper/pojo/schema/management/strategy/SchemaManagementStrategyCreateOrUpdateIT.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.search.integrationtest.mapper.pojo.schema.management.strategy;
import org.hibernate.search.mapper.pojo.standalone.schema.management.SchemaManagementStrategyName;
import org.hibernate.search.util.impl.integrationtest.common.extension.SchemaManagementWorkBehavior;
import org.hibernate.search.util.impl.integrationtest.common.stub.backend.index.StubSchemaManagementWork;
class SchemaManagementStrategyCreateOrUpdateIT extends AbstractSchemaManagementStrategyIT {
@Override
protected SchemaManagementStrategyName getStrategyName() {
return SchemaManagementStrategyName.CREATE_OR_UPDATE;
}
@Override
protected void expectWork(String indexName, SchemaManagementWorkBehavior behavior) {
backendMock.expectSchemaManagementWorks( indexName )
.work( StubSchemaManagementWork.Type.CREATE_OR_UPDATE, behavior );
}
@Override
protected void expectOnClose(String indexName) {
// No expectation
}
}
|
hibernate/hibernate-search | 1,056 | mapper/pojo-base/src/main/java/org/hibernate/search/mapper/pojo/bridge/runtime/impl/IdentifierBridgeToDocumentIdentifierContextImpl.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.search.mapper.pojo.bridge.runtime.impl;
import org.hibernate.search.engine.common.dsl.spi.DslExtensionState;
import org.hibernate.search.mapper.pojo.bridge.runtime.IdentifierBridgeToDocumentIdentifierContext;
import org.hibernate.search.mapper.pojo.bridge.runtime.IdentifierBridgeToDocumentIdentifierContextExtension;
import org.hibernate.search.mapper.pojo.bridge.runtime.spi.BridgeMappingContext;
public class IdentifierBridgeToDocumentIdentifierContextImpl implements IdentifierBridgeToDocumentIdentifierContext {
private final BridgeMappingContext mappingContext;
public IdentifierBridgeToDocumentIdentifierContextImpl(BridgeMappingContext mappingContext) {
this.mappingContext = mappingContext;
}
@Override
public <T> T extension(IdentifierBridgeToDocumentIdentifierContextExtension<T> extension) {
return DslExtensionState.returnIfSupported(
extension,
extension.extendOptional( this, mappingContext )
);
}
}
|
hibernate/hibernate-search | 1,094 | backend/lucene/src/main/java/org/hibernate/search/backend/lucene/work/impl/LuceneSearcher.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.search.backend.lucene.work.impl;
import java.io.IOException;
import org.hibernate.search.backend.lucene.lowlevel.reader.impl.IndexReaderMetadataResolver;
import org.hibernate.search.engine.search.timeout.spi.TimeoutManager;
import org.apache.lucene.search.Explanation;
import org.apache.lucene.search.IndexSearcher;
import org.apache.lucene.search.Query;
public interface LuceneSearcher<R, ER> {
R search(IndexSearcher indexSearcher, IndexReaderMetadataResolver metadataResolver,
int offset, Integer limit, int totalHitCountThreshold)
throws IOException;
ER scroll(IndexSearcher indexSearcher, IndexReaderMetadataResolver metadataResolver,
int offset, int limit, int totalHitCountThreshold)
throws IOException;
int count(IndexSearcher indexSearcher) throws IOException;
Explanation explain(IndexSearcher indexSearcher, int luceneDocId) throws IOException;
Query getLuceneQueryForExceptions();
void setTimeoutManager(TimeoutManager timeoutManager);
}
|
openjdk/jdk8 | 1,150 | langtools/test/com/sun/javadoc/testMemberInheritence/inheritDist/A.java | /*
* Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package inheritDist;
//6270645
public interface A {
/**
* m1-A
*/
void m1();
}
|
openjdk/jdk8 | 1,155 | langtools/test/com/sun/javadoc/testMemberInheritence/diamond/Z.java | /*
* Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package diamond;
public interface Z extends X, C {
/**
* zDoc.
*/
void zMethod();
}
|
openjdk/jdk8 | 1,160 | jdk/test/java/lang/instrument/bootreporter/StringIdCallback.java | /*
* Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package bootreporter;
public interface StringIdCallback {
public void tracker(String name, int id);
}
|
oracle/coherence | 1,123 | prj/coherence-core/src/main/java/com/tangosol/dev/assembler/If_acmpne.java | /*
* Copyright (c) 2000, 2020, Oracle and/or its affiliates.
*
* Licensed under the Universal Permissive License v 1.0 as shown at
* http://oss.oracle.com/licenses/upl.
*/
package com.tangosol.dev.assembler;
import java.io.IOException;
import java.io.DataInput;
import java.io.DataOutput;
/**
* The IF_ACMPNE op branches to the label if the top two references on the
* stack are not equal.
* <p><code><pre>
* JASM op : IF_ACMPNE (0xa6)
* JVM byte code(s): IF_ACMPNE (0xa6)
* Details :
* </pre></code>
*
* @version 0.50, 06/14/98, assembler/dis-assembler
* @author Cameron Purdy
*/
public class If_acmpne extends OpBranch implements Constants
{
// ----- constructors ---------------------------------------------------
/**
* Construct the op.
*
* @param label the label to branch to
*/
public If_acmpne(Label label)
{
super(IF_ACMPNE, label);
}
// ----- data members ---------------------------------------------------
/**
* The name of this class.
*/
private static final String CLASS = "If_acmpne";
}
|
apache/commons-vfs | 1,129 | commons-vfs2/src/test/java/org/apache/commons/vfs2/filter/AlwaysFalseFileFilter.java | /*
* 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
*
* https://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.apache.commons.vfs2.filter;
import org.apache.commons.vfs2.FileFilter;
import org.apache.commons.vfs2.FileSelectInfo;
/**
* Always FALSE.
*/
final class AlwaysFalseFileFilter implements FileFilter {
@Override
public boolean accept(final FileSelectInfo fileSelectInfo) {
return false;
}
} |
apache/deltaspike | 1,077 | deltaspike/core/impl/obsolete/src/test/java/org/apache/deltaspike/test/core/api/alternative/global/BaseInterface1DefaultImplementation.java | /*
* 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.apache.deltaspike.test.core.api.alternative.global;
import jakarta.enterprise.context.Dependent;
/**
* Default implementation which gets overruled by the alternative
*/
@Dependent
public class BaseInterface1DefaultImplementation implements BaseInterface1
{
}
|
apache/deltaspike | 1,103 | deltaspike/core/impl/obsolete/src/test/java/org/apache/deltaspike/test/core/api/alternative/local/BaseBean2.java | /*
* 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.apache.deltaspike.test.core.api.alternative.local;
import jakarta.enterprise.context.Dependent;
/**
* Simple base bean which doesn't get overruled by an global alternative
*/
//Workaround until different config files for unit tests work correctly
@Dependent
public class BaseBean2
{
}
|
apache/directory-kerby | 1,118 | kerby-kerb/kerb-gssapi/src/main/java/org/apache/kerby/kerberos/kerb/gss/impl/GssTokenBase.java | /**
* 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.apache.kerby.kerberos.kerb.gss.impl;
public abstract class GssTokenBase {
public static final int TOKEN_WRAP_V1 = 0x201;
public static final int TOKEN_MIC_V1 = 0x101;
public static final int TOKEN_WRAP_V2 = 0x504;
public static final int TOKEN_MIC_V2 = 0x404;
}
|
apache/dolphinscheduler | 1,105 | dolphinscheduler-spi/src/main/java/org/apache/dolphinscheduler/spi/datasource/ConnectionParam.java | /*
* 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.apache.dolphinscheduler.spi.datasource;
import java.io.Serializable;
/**
* The model of Datasource Connection param
*/
public interface ConnectionParam extends Serializable {
default String getPassword() {
return "";
}
default void setPassword(String s) {
}
}
|
apache/dolphinscheduler | 1,114 | dolphinscheduler-dao/src/main/java/org/apache/dolphinscheduler/dao/entity/WorkFlowLineage.java | /*
* 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.apache.dolphinscheduler.dao.entity;
import java.util.List;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@NoArgsConstructor
public class WorkFlowLineage {
private List<WorkFlowRelation> workFlowRelationList;
private List<WorkFlowRelationDetail> workFlowRelationDetailList;
}
|
apache/doris-manager | 1,122 | manager/general/src/main/java/org/apache/doris/stack/entity/StudioSettingEntityPk.java | // 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.apache.doris.stack.entity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serializable;
@Data
@NoArgsConstructor
@AllArgsConstructor
public class StudioSettingEntityPk implements Serializable {
private String key;
private long clusterId;
}
|
apache/doris-spark-connector | 1,121 | spark-load/spark-load-core/src/main/java/org/apache/doris/common/LoadInfo.java | // 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.apache.doris.common;
import lombok.Data;
import java.util.List;
@Data
public class LoadInfo {
private String dbName;
private List<String> tblNames;
private String label;
private String clusterName;
private String state;
private String failMsg;
private String trackingUrl;
}
|
apache/drill | 1,117 | exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/project/OutputWidthVisitorState.java | /*
* 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.apache.drill.exec.physical.impl.project;
public class OutputWidthVisitorState {
ProjectMemoryManager manager;
public OutputWidthVisitorState(ProjectMemoryManager manager) {
this.manager = manager;
}
public ProjectMemoryManager getManager() {
return manager;
}
}
|
apache/druid | 1,069 | extensions-core/datasketches/src/main/java/org/apache/druid/query/aggregation/datasketches/tuple/sql/ArrayOfDoublesSketchSetNotOperatorConversion.java | /*
* 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.apache.druid.query.aggregation.datasketches.tuple.sql;
public class ArrayOfDoublesSketchSetNotOperatorConversion extends ArrayOfDoublesSketchSetBaseOperatorConversion
{
@Override
public String getSetOperationName()
{
return "NOT";
}
}
|
apache/druid | 1,126 | indexing-service/src/main/java/org/apache/druid/metadata/MetadataStorageActionHandlerTypes.java | /*
* 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.apache.druid.metadata;
import com.fasterxml.jackson.core.type.TypeReference;
public interface MetadataStorageActionHandlerTypes<EntryType, StatusType, LogType, LockType>
{
TypeReference<EntryType> getEntryType();
TypeReference<StatusType> getStatusType();
TypeReference<LockType> getLockType();
}
|
apache/druid | 1,152 | sql/src/test/java/org/apache/druid/quidem/SqlQuidemTest.java | /*
* 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.apache.druid.quidem;
import java.io.File;
public class SqlQuidemTest extends DruidQuidemTestBase
{
public SqlQuidemTest()
{
super(new DruidQuidemCommandHandler());
}
@Override
protected File getTestRoot()
{
return ProjectPathUtils.getPathFromProjectRoot("sql/src/test/quidem/" + getClass().getName());
}
}
|
apache/dubbo-samples | 1,101 | 2-advanced/dubbo-samples-version/src/main/java/org/apache/dubbo/samples/version/impl/VersionServiceImpl.java | /*
*
* 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.apache.dubbo.samples.version.impl;
import org.apache.dubbo.samples.version.api.VersionService;
public class VersionServiceImpl implements VersionService {
@Override
public String sayHello(String name) {
return "hello, " + name;
}
}
|
apache/dubbo | 1,120 | dubbo-registry/dubbo-registry-api/src/test/java/org/apache/dubbo/registry/SimpleRegistryFactory.java | /*
* 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.apache.dubbo.registry;
import org.apache.dubbo.common.URL;
import org.mockito.Mockito;
public class SimpleRegistryFactory implements RegistryFactory {
static Registry registry = Mockito.mock(Registry.class);
@Override
public Registry getRegistry(URL url) {
return registry;
}
}
|
apache/dubbo | 1,121 | dubbo-remoting/dubbo-remoting-api/src/main/java/org/apache/dubbo/remoting/api/pu/ChannelOperator.java | /*
* 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.apache.dubbo.remoting.api.pu;
import org.apache.dubbo.remoting.ChannelHandler;
import org.apache.dubbo.remoting.api.ProtocolDetector;
import java.util.List;
public interface ChannelOperator {
void configChannelHandler(List<ChannelHandler> handlerList);
ProtocolDetector.Result detectResult();
}
|
apache/eventmesh | 1,070 | eventmesh-connectors/eventmesh-connector-mongodb/src/main/java/org/apache/eventmesh/connector/mongodb/sink/client/Impl/MongodbSinkClient.java | /*
* 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.apache.eventmesh.connector.mongodb.sink.client.Impl;
import io.cloudevents.CloudEvent;
/**
* MongodbSinkClient
*/
public interface MongodbSinkClient {
void init();
void start();
void publish(CloudEvent cloudEvent);
void stop();
}
|
apache/eventmesh | 1,104 | eventmesh-admin-server/src/main/java/org/apache/eventmesh/admin/server/web/db/service/EventMeshVerifyService.java | /*
* 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.apache.eventmesh.admin.server.web.db.service;
import org.apache.eventmesh.admin.server.web.db.entity.EventMeshVerify;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* event_mesh_verify
*/
public interface EventMeshVerifyService extends IService<EventMeshVerify> {
}
|
apache/felix-dev | 1,074 | ipojo/runtime/core-it/ipojo-core-annotations-test/src/main/java/org/apache/felix/ipojo/runtime/core/test/components/InstantiateWithName.java | /*
* 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.apache.felix.ipojo.runtime.core.test.components;
import org.apache.felix.ipojo.annotations.Component;
import org.apache.felix.ipojo.annotations.Instantiate;
@Instantiate(name="myInstantiatedInstance")
@Component
public class InstantiateWithName {
}
|
apache/fineract | 1,081 | fineract-e2e-tests-core/src/test/java/org/apache/fineract/test/messaging/event/loan/transaction/LoanTransactionPayoutRefundPostEvent.java | /**
* 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.apache.fineract.test.messaging.event.loan.transaction;
public class LoanTransactionPayoutRefundPostEvent extends AbstractLoanTransactionEvent {
@Override
public String getEventName() {
return "LoanTransactionPayoutRefundPostBusinessEvent";
}
}
|
apache/fineract | 1,087 | fineract-loan/src/main/java/org/apache/fineract/portfolio/loanaccount/rescheduleloan/service/LoanReschedulePreviewPlatformService.java | /**
* 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.apache.fineract.portfolio.loanaccount.rescheduleloan.service;
import org.apache.fineract.portfolio.loanaccount.loanschedule.domain.LoanScheduleModel;
public interface LoanReschedulePreviewPlatformService {
LoanScheduleModel previewLoanReschedule(Long requestId);
}
|
apache/fineract | 1,115 | fineract-core/src/main/java/org/apache/fineract/infrastructure/dataqueries/data/ReportExportType.java | /**
* 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.apache.fineract.infrastructure.dataqueries.data;
import java.io.Serializable;
import lombok.Data;
import lombok.RequiredArgsConstructor;
@Data
@RequiredArgsConstructor
public class ReportExportType implements Serializable {
private final String key;
private final String queryParameter;
}
|
apache/flink-agents | 1,127 | runtime/src/main/java/org/apache/flink/agents/runtime/feedback/FeedbackConsumer.java | /*
* 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.apache.flink.agents.runtime.feedback;
/**
* NOTE: This source code was copied from the <a
* href="https://github.com/apache/flink-statefun">flink-statefun</a>
*
* <p>HandOffConsumer.
*/
@FunctionalInterface
public interface FeedbackConsumer<T> {
void processFeedback(T element) throws Exception;
}
|
apache/flink | 1,094 | flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/operations/materializedtable/MaterializedTableOperation.java | /*
* 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.apache.flink.table.operations.materializedtable;
import org.apache.flink.annotation.Internal;
import org.apache.flink.table.operations.Operation;
/** The marker interface for materialized table. */
@Internal
public interface MaterializedTableOperation extends Operation {}
|
apache/flink | 1,116 | flink-libraries/flink-state-processing-api/src/test/java/org/apache/flink/state/api/utils/ReduceSum.java | /*
* 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.apache.flink.state.api.utils;
import org.apache.flink.api.common.functions.ReduceFunction;
/** A simple sum reducer. */
public class ReduceSum implements ReduceFunction<Integer> {
@Override
public Integer reduce(Integer value1, Integer value2) {
return value1 + value2;
}
}
|
apache/fluss | 1,133 | fluss-common/src/main/java/org/apache/fluss/exception/InvalidTimestampException.java | /*
* 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.apache.fluss.exception;
import org.apache.fluss.annotation.PublicEvolving;
/**
* Exception thrown when the timestamp is invalid.
*
* @since 0.2
*/
@PublicEvolving
public class InvalidTimestampException extends ApiException {
public InvalidTimestampException(String message) {
super(message);
}
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.