repo_id
stringclasses
875 values
size
int64
974
38.9k
file_path
stringlengths
10
308
content
stringlengths
974
38.9k
apache/ranger
1,098
agents-common/src/main/java/org/apache/ranger/plugin/policyevaluator/RangerDataMaskPolicyItemEvaluator.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.ranger.plugin.policyevaluator; import org.apache.ranger.plugin.model.RangerPolicy.RangerPolicyItemDataMaskInfo; public interface RangerDataMaskPolicyItemEvaluator extends RangerPolicyItemEvaluator { void init(); RangerPolicyItemDataMaskInfo getDataMaskInfo(); }
apache/reef
1,108
lang/java/reef-examples/src/main/java/org/apache/reef/examples/group/bgd/ControlMessages.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.reef.examples.group.bgd; import java.io.Serializable; /** * Control messages used in BGD example. */ public enum ControlMessages implements Serializable { ComputeGradientWithModel, ComputeGradientWithMinEta, DoLineSearch, DoLineSearchWithModel, Synchronize, Stop }
apache/reef
1,114
lang/java/reef-webserver/src/main/java/org/apache/reef/webserver/HttpEventHandlers.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.reef.webserver; import org.apache.reef.tang.annotations.Name; import org.apache.reef.tang.annotations.NamedParameter; import java.util.Set; /** * HttpEventHandlers. */ @NamedParameter(doc = "Http Event Handlers") public class HttpEventHandlers implements Name<Set<HttpHandler>> { }
apache/rocketmq-eventbridge
1,097
domain/src/main/java/org/apache/rocketmq/eventbridge/domain/model/classes/APIAttribute.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.eventbridge.domain.model.classes; import lombok.AllArgsConstructor; import lombok.Data; @AllArgsConstructor @Data public class APIAttribute { private String type; private String description; private boolean required; private Object defaultValue; }
apache/rocketmq-exporter
1,119
src/main/java/org/apache/rocketmq/exporter/service/RMQMetricsService.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.exporter.service; import org.apache.rocketmq.exporter.collector.RMQMetricsCollector; import java.io.IOException; import java.io.StringWriter; public interface RMQMetricsService { RMQMetricsCollector getCollector(); void metrics(StringWriter writer) throws IOException; }
apache/seatunnel
1,069
seatunnel-e2e/seatunnel-connector-v2-e2e/connector-redis-e2e/src/test/java/org/apache/seatunnel/e2e/connector/redis/Redis5IT.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.e2e.connector.redis; public class Redis5IT extends RedisTestCaseTemplateIT { @Override public RedisContainerInfo getRedisContainerInfo() { return new RedisContainerInfo("redis-e2e", 6379, "SeaTunnel", "redis:5"); } }
apache/seatunnel
1,069
seatunnel-e2e/seatunnel-connector-v2-e2e/connector-redis-e2e/src/test/java/org/apache/seatunnel/e2e/connector/redis/Redis7IT.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.e2e.connector.redis; public class Redis7IT extends RedisTestCaseTemplateIT { @Override public RedisContainerInfo getRedisContainerInfo() { return new RedisContainerInfo("redis-e2e", 6379, "SeaTunnel", "redis:7"); } }
apache/seatunnel
1,085
seatunnel-engine/seatunnel-engine-core/src/main/java/org/apache/seatunnel/engine/core/checkpoint/Checkpoint.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.engine.core.checkpoint; /** A checkpoint, pending or completed. */ public interface Checkpoint { long getCheckpointId(); int getPipelineId(); long getJobId(); long getCheckpointTimestamp(); CheckpointType getCheckpointType(); }
apache/servicecomb-toolkit
1,060
oas-validator/oas-validator-core/src/main/java/org/apache/servicecomb/toolkit/oasv/diffvalidation/factory/PathsDiffValidatorFactory.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.PathsDiffValidator; public interface PathsDiffValidatorFactory extends OasObjectDiffValidatorFactory<PathsDiffValidator> { }
apache/servicecomb-toolkit
1,064
oas-validator/oas-validator-style/src/main/java/org/apache/servicecomb/toolkit/oasv/style/factory/ValidatorFactoryComponents.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.style.factory; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; @Configuration @ComponentScan public interface ValidatorFactoryComponents { }
apache/shardingsphere
1,078
agent/core/src/main/java/org/apache/shardingsphere/agent/core/plugin/config/yaml/entity/YamlAgentConfiguration.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.agent.core.plugin.config.yaml.entity; import lombok.Getter; import lombok.Setter; /** * YAML agent configuration. */ @Getter @Setter public final class YamlAgentConfiguration { private YamlPluginCategoryConfiguration plugins; }
apache/shenyu
1,122
shenyu-admin/src/test/java/org/apache/shenyu/admin/model/vo/AuthPathVOTest.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 AuthPathVO. */ public final class AuthPathVOTest extends AbstractReflectGetterSetterTest { @Override protected Class<?> getTargetClass() { return AuthPathVO.class; } }
apache/shenyu
1,122
shenyu-admin/src/test/java/org/apache/shenyu/admin/model/vo/MetaDataVOTest.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 MetaDataVO. */ public final class MetaDataVOTest extends AbstractReflectGetterSetterTest { @Override protected Class<?> getTargetClass() { return MetaDataVO.class; } }
apache/shenyu
1,122
shenyu-admin/src/test/java/org/apache/shenyu/admin/model/vo/SelectorVOTest.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 SelectorVO. */ public final class SelectorVOTest extends AbstractReflectGetterSetterTest { @Override protected Class<?> getTargetClass() { return SelectorVO.class; } }
apache/sis
1,103
endorsed/src/org.apache.sis.storage.geotiff/main/org/apache/sis/storage/geotiff/base/Resources_en.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.sis.storage.geotiff.base; /** * Resource in English language. */ public class Resources_en extends Resources { /** * Constructs a new resource bundle loading data from * the resource file of the same name as this class. */ public Resources_en() { } }
apache/skywalking-java
1,042
test/plugin/scenarios/shardingsphere-3.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/shardingsphere/service/api/repository/OrderRepository.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.Order; public interface OrderRepository extends CommonRepository<Order> { }
apache/skywalking-java
1,042
test/plugin/scenarios/shardingsphere-4.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/shardingsphere/service/api/repository/OrderRepository.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.Order; public interface OrderRepository extends CommonRepository<Order> { }
apache/skywalking-java
1,074
apm-application-toolkit/apm-toolkit-meter/src/test/java/org/apache/skywalking/apm/toolkit/meter/CounterTest.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.toolkit.meter; import org.junit.Assert; import org.junit.Test; public class CounterTest { @Test public void testBuild() { Assert.assertNotNull(MeterFactory.counter("test_counter").tag("k1", "v1").build()); } }
apache/solr
1,128
solr/core/src/java/org/apache/solr/cluster/events/CollectionsAddedEvent.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.solr.cluster.events; import java.util.Iterator; /** Event generated when some collections have been added. */ public interface CollectionsAddedEvent extends ClusterEvent { @Override default EventType getType() { return EventType.COLLECTIONS_ADDED; } Iterator<String> getCollectionNames(); }
apache/stratos
1,060
components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/listener/domain/mapping/DomainMappingAddedEventListener.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.stratos.messaging.listener.domain.mapping; import org.apache.stratos.messaging.listener.EventListener; /** * Domain name added event listener. */ public abstract class DomainMappingAddedEventListener extends EventListener { }
apache/streampark
1,082
streampark-flink/streampark-flink-packer/src/main/java/com/github/dockerjava/api/listener/PullImageCallbackListener.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 com.github.dockerjava.api.listener; import com.github.dockerjava.api.model.PullResponseItem; public interface PullImageCallbackListener { /** Watch pull image process information form docker rest api. */ void watchPullProcess(PullResponseItem processDetail); }
apache/streampark
1,082
streampark-flink/streampark-flink-packer/src/main/java/com/github/dockerjava/api/listener/PushImageCallbackListener.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 com.github.dockerjava.api.listener; import com.github.dockerjava.api.model.PushResponseItem; public interface PushImageCallbackListener { /** Watch push image process information form docker rest api. */ void watchPushProcess(PushResponseItem processDetail); }
apache/streampipes
1,111
streampipes-vocabulary/src/main/java/org/apache/streampipes/vocabulary/RDFS.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.streampipes.vocabulary; public class RDFS { public static final String NS = "http://www.w3.org/2000/01/rdf-schema#"; public static final String NS_PREFIX = "rdfs"; public static final String LABEL = NS + "label"; public static final String DESCRIPTION = NS + "description"; }
apache/syncope
1,089
core/persistence-neo4j/src/main/java/org/apache/syncope/core/persistence/neo4j/dao/repo/SAML2SPClientAppRepoExt.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.syncope.core.persistence.neo4j.dao.repo; import org.apache.syncope.core.persistence.api.entity.am.SAML2SPClientApp; public interface SAML2SPClientAppRepoExt extends ClientAppRepoExt<SAML2SPClientApp> { SAML2SPClientApp save(SAML2SPClientApp clientApp); }
apache/tajo
1,122
tajo-plan/src/main/java/org/apache/tajo/plan/expr/EvalTreeFactory.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.plan.expr; import org.apache.tajo.datum.Datum; public class EvalTreeFactory { public static ConstEval newConst(Datum datum) { return new ConstEval(datum); } public static BinaryEval create(EvalType type, EvalNode e1, EvalNode e2) { return new BinaryEval(type, e1, e2); } }
apache/tapestry-5
1,079
tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/components/SubclassWithFinalCachedMethod.java
// Copyright 2024 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.integration.app1.components; import java.util.Arrays; import java.util.List; import org.apache.tapestry5.annotations.Property; public class SubclassWithFinalCachedMethod extends SuperclassWithFinalCachedMethod { @Property private int clientId = 2; private int counter = 10; @Override protected List<?> createList() { return Arrays.asList("subclass", String.valueOf(counter++)); } }
apache/tapestry-5
1,102
tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/FlashDemo.java
// Copyright 2007 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.integration.app1.pages; import org.apache.tapestry5.annotations.Meta; import org.apache.tapestry5.annotations.Persist; import org.apache.tapestry5.integration.app1.base.BaseComponent; @Meta("tapestry.persistence-strategy=flash") public class FlashDemo extends BaseComponent { @Persist private String message; public String getMessage() { return message; } void onAction() { message = "You clicked the link!"; } }
apache/tapestry-5
1,108
tapestry-core/src/main/java/org/apache/tapestry5/internal/util/Base64OutputStream.java
// Copyright 2006 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.util; import org.apache.commons.codec.binary.Base64; import java.io.ByteArrayOutputStream; /** * An extension of {@link ByteArrayOutputStream} that allows the final byte array to be converted to a Base64 string. */ public final class Base64OutputStream extends ByteArrayOutputStream { public String toBase64() { byte[] binary = toByteArray(); byte[] base64 = Base64.encodeBase64(binary); return new String(base64); } }
apache/tapestry-5
1,117
tapestry-func/src/test/java/org/apache/tapestry5/func/FlowToSetTests.java
// Copyright 2010 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.func; import java.util.Arrays; import java.util.Collections; import java.util.Set; import org.testng.annotations.Test; public class FlowToSetTests extends BaseFuncTest { @Test public void empty_flow_to_set() { assertSame(F.emptyFlow().toSet(), Collections.EMPTY_SET); } @Test public void nonempty_flow() { Set<Integer> set = F.range(1, 10).filter(evenp).toSet(); assertTrue(set.containsAll(Arrays.asList(2, 4, 6, 8))); } }
apache/tika
1,101
tika-eval/tika-eval-core/src/main/java/org/apache/tika/eval/core/textstats/TokenCountStatsCalculator.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.tika.eval.core.textstats; import org.apache.tika.eval.core.tokens.TokenCounts; /** * Interface for calculators that require token stats * * @param <T> */ public interface TokenCountStatsCalculator<T> extends TextStatsCalculator { T calculate(TokenCounts tokenCounts); }
apache/tika
1,143
tika-core/src/main/java/org/apache/tika/metadata/PST.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.tika.metadata; public interface PST { String PST_PREFIX = "pst:"; Property PST_FOLDER_PATH = Property.internalText(PST_PREFIX + "folderPath"); Property DESCRIPTOR_NODE_ID = Property.internalText(PST_PREFIX + "discriptorNodeId"); Property IS_VALID = Property.internalBoolean(PST_PREFIX + "isValid"); }
apache/tomcat
1,154
java/org/apache/el/parser/ArithmeticNode.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.el.parser; import jakarta.el.ELException; import org.apache.el.lang.EvaluationContext; public abstract class ArithmeticNode extends SimpleNode { public ArithmeticNode(int i) { super(i); } @Override public Class<?> getType(EvaluationContext ctx) throws ELException { return Number.class; } }
apache/tomee
1,059
arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/requestdispose/SomePojo.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.arquillian.tests.requestdispose; public class SomePojo implements Pojo { public SomePojo(final String justHereToAvoidToBeManaged) { // no-op } @Override public void foo() { // no-op } }
apache/tomee
1,109
tomee/tomee-security/src/main/java/org/apache/tomee/security/http/openid/model/TomEEJwtClaims.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.tomee.security.http.openid.model; import jakarta.json.JsonObject; import jakarta.security.enterprise.identitystore.openid.JwtClaims; public class TomEEJwtClaims extends TomEEJsonClaims implements JwtClaims { public TomEEJwtClaims(JsonObject claims) { super(claims); } }
apache/tomee
1,114
container/openejb-core/src/main/java/org/apache/openejb/resource/PropertiesFactory.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.resource; import java.util.Properties; public class PropertiesFactory { private Properties properties; public void setProperties(final Properties properties) { this.properties = properties; } public Properties create() { return properties; } }
apache/trafodion
1,118
dcs/src/main/java/org/trafodion/dcs/master/listener/DataEvent.java
/** * @@@ START COPYRIGHT @@@ 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. * @@@ END COPYRIGHT @@@ */ package org.trafodion.dcs.master.listener; import java.nio.*; import java.nio.channels.*; import java.nio.channels.spi.*; class DataEvent { public ListenerService server; SelectionKey key; public DataEvent(ListenerService server, SelectionKey key) { this.server = server; this.key = key; } }
apache/uniffle
1,120
common/src/main/java/org/apache/uniffle/common/exception/NoBufferException.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.uniffle.common.exception; public class NoBufferException extends RssException { public NoBufferException(String message) { super(message); } public NoBufferException(Throwable e) { super(e); } public NoBufferException(String message, Throwable e) { super(message, e); } }
apache/uniffle
1,144
cli/src/main/java/org/apache/uniffle/client/RestClient.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.uniffle.client; import java.util.Map; /** A underlying http client interface for common rest request. */ public interface RestClient extends AutoCloseable, Cloneable { String get(String path, Map<String, Object> params, String authHeader); String post(String path, Map<String, Object> params, String authHeader); }
apache/wicket
1,109
wicket-core-tests/src/test/java/org/apache/wicket/markup/html/link/Page1.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.markup.html.link; import org.apache.wicket.markup.html.WebPage; /** * Mock page for testing autolinks * * @author Chris Turner */ public class Page1 extends WebPage { private static final long serialVersionUID = 1L; /** * Construct. * */ public Page1() { } }
apache/xmlgraphics-fop
1,124
fop-core/src/main/java/org/apache/fop/render/ps/PSRenderingMode.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.render.ps; /** * Enumeration that specifies the rendering mode for PostScript output. {@link #SIZE} tries * to produce smaller files at the expense of quality, whereas {@link #QUALITY} tries to * produce the best possible quality. */ enum PSRenderingMode { SIZE, QUALITY; }
google/bindiff
1,082
java/zylib/src/main/java/com/google/security/zynamics/zylib/gui/zygraph/editmode/actions/CDefaultNodePressedMiddleAction.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.zylib.gui.zygraph.editmode.actions; import com.google.security.zynamics.zylib.gui.zygraph.editmode.IStateAction; import com.google.security.zynamics.zylib.yfileswrap.gui.zygraph.editmode.states.CNodePressedMiddleState; import java.awt.event.MouseEvent; public class CDefaultNodePressedMiddleAction implements IStateAction<CNodePressedMiddleState> { @Override public void execute(final CNodePressedMiddleState state, final MouseEvent event) {} }
google/copybara
1,131
java/com/google/copybara/remotefile/RemoteArchiveVersionSelector.java
/* * Copyright (C) 2022 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.copybara.remotefile; import com.beust.jcommander.internal.Nullable; import com.google.copybara.exception.ValidationException; /** * An interface for version selecting logic to use with a RemoteArchiveOrigin object. Individual * implementations should be exposed as @StarlarkBuiltin objects */ public interface RemoteArchiveVersionSelector { public RemoteArchiveVersion constructUrl( String baseUrl, @Nullable String requestedRef, RemoteFileOptions remoteFileOptions) throws ValidationException; }
google/depan
1,108
DepanViewDoc/prod/src/com/google/devtools/depan/eclipse/visualization/ogl/GLLogger.java
/* * Copyright 2017 The Depan Project 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.devtools.depan.eclipse.visualization.ogl; import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** * Provide a common logger for the OGL rendering layer. * Simply import this class, and use the available {@link #LOG} member. * * @author <a href="mailto:leeca@pnambic.com">Lee Carver</a> */ public class GLLogger { public static final Logger LOG = LoggerFactory.getLogger(GLLogger.class.getName()); private GLLogger() { // Prevent instantiation. } }
google/gdata-java-client
1,124
java/src/com/google/gdata/wireformats/input/InputProperties.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.input; import com.google.gdata.wireformats.StreamProperties; /** * The InputProperties interface represents properties of a input data being * parsed. * * @see InputParser */ public interface InputProperties extends StreamProperties { /** * Returns the expected root type that will be produced as a result of parsing * the content. The parse result will be of this type or a subtype that * extends or implements the root type. */ public Class<?> getRootType(); }
google/guava
1,125
guava-tests/test/com/google/common/collect/CompactHashMapFloodingTest.java
/* * Copyright (C) 2012 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.Math.log; import com.google.common.annotations.GwtIncompatible; import java.util.Map; import org.jspecify.annotations.NullUnmarked; @GwtIncompatible @NullUnmarked public class CompactHashMapFloodingTest extends AbstractHashFloodingTest<Map<Object, Object>> { public CompactHashMapFloodingTest() { super( ImmutableList.of(Construction.mapFromKeys(CompactHashMap::create)), n -> n * log(n), ImmutableList.of(QueryOp.MAP_GET)); } }
google/j2cl
1,120
transpiler/java/com/google/j2cl/transpiler/passes/RemoveCustomIsInstanceMethods.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 * * 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.j2cl.transpiler.passes; import com.google.j2cl.transpiler.ast.Type; /** * Removes user written {@code $isInstance} methods. {@code $isInstance} is unused in Wasm, and the * explicit implementations in our JRE in {@code Comparable}, etc use a native type in a way that is * unsupported in Wasm. */ public class RemoveCustomIsInstanceMethods extends NormalizationPass { @Override public void applyTo(Type type) { type.getMembers().removeIf(m -> m.getDescriptor().isCustomIsInstanceMethod()); } }
google/j2cl
1,141
jre/java/javasynth/java/lang/invoke/LambdaMetafactory.java
/* * Copyright 2019 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 java.lang.invoke; /** Exists solely to make javac happy. */ public class LambdaMetafactory { public static CallSite metafactory( MethodHandles.Lookup caller, String interfaceMethodName, MethodType factoryType, MethodType interfaceMethodType, MethodHandle implementation, MethodType dynamicMethodType) { return null; } public static CallSite altMetafactory( MethodHandles.Lookup caller, String interfaceMethodName, MethodType factoryType, Object... a) { return null; } }
google/j2objc
1,087
jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/impl/locale/ParseStatus.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) 2010, International Business Machines Corporation and * * others. All Rights Reserved. * ******************************************************************************* */ package android.icu.impl.locale; /** * @hide Only a subset of ICU is exposed in Android */ public class ParseStatus { int _parseLength = 0; int _errorIndex = -1; String _errorMsg = null; public void reset() { _parseLength = 0; _errorIndex = -1; _errorMsg = null; } public boolean isError() { return (_errorIndex >= 0); } public int getErrorIndex() { return _errorIndex; } public int getParseLength() { return _parseLength; } public String getErrorMessage() { return _errorMsg; } }
google/mail-importer
1,133
src/main/java/to/lean/tools/gmail/importer/FlagsModule.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; import com.google.inject.AbstractModule; /** Makes the command line arguments available through Guice. */ public class FlagsModule extends AbstractModule { private final CommandLineArguments commandLineArguments; public FlagsModule(CommandLineArguments commandLineArguments) { this.commandLineArguments = commandLineArguments; } @Override protected void configure() { bind(CommandLineArguments.class).toInstance(commandLineArguments); } }
google/nomulus
1,097
core/src/main/java/google/registry/flows/exceptions/TransferPeriodZeroAndFeeTransferExtensionException.java
// Copyright 2017 The Nomulus 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 google.registry.flows.exceptions; import google.registry.flows.EppException.StatusProhibitsOperationException; /** Domain transfer period cannot be zero when using the fee transfer extension. */ public class TransferPeriodZeroAndFeeTransferExtensionException extends StatusProhibitsOperationException { public TransferPeriodZeroAndFeeTransferExtensionException() { super("Domain transfer period cannot be zero when using the fee transfer extension."); } }
google/oss-fuzz
1,163
projects/xmlbeans/regExFuzzer.java
// Copyright 2023 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. // //////////////////////////////////////////////////////////////////////////////// import com.code_intelligence.jazzer.api.FuzzedDataProvider; import org.apache.xmlbeans.impl.regex.RegularExpression; public class regExFuzzer { public static void fuzzerTestOneInput(FuzzedDataProvider data) { String regExStr = data.consumeString(100); String parse = data.consumeRemainingAsString(); try { RegularExpression regex = new RegularExpression(regExStr); regex.matches(parse); } catch(Exception e){} } }
googleads/google-ads-java
1,072
google-ads-stubs-v19/src/main/java/com/google/ads/googleads/v19/common/AdDemandGenCarouselCardAssetOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v19/common/ad_asset.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v19.common; public interface AdDemandGenCarouselCardAssetOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v19.common.AdDemandGenCarouselCardAsset) com.google.protobuf.MessageOrBuilder { /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return Whether the asset field is set. */ boolean hasAsset(); /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return The asset. */ java.lang.String getAsset(); /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return The bytes for asset. */ com.google.protobuf.ByteString getAssetBytes(); }
googleads/google-ads-java
1,072
google-ads-stubs-v20/src/main/java/com/google/ads/googleads/v20/common/AdDemandGenCarouselCardAssetOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v20/common/ad_asset.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v20.common; public interface AdDemandGenCarouselCardAssetOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v20.common.AdDemandGenCarouselCardAsset) com.google.protobuf.MessageOrBuilder { /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return Whether the asset field is set. */ boolean hasAsset(); /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return The asset. */ java.lang.String getAsset(); /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return The bytes for asset. */ com.google.protobuf.ByteString getAssetBytes(); }
googleads/google-ads-java
1,072
google-ads-stubs-v21/src/main/java/com/google/ads/googleads/v21/common/AdDemandGenCarouselCardAssetOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v21/common/ad_asset.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v21.common; public interface AdDemandGenCarouselCardAssetOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v21.common.AdDemandGenCarouselCardAsset) com.google.protobuf.MessageOrBuilder { /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return Whether the asset field is set. */ boolean hasAsset(); /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return The asset. */ java.lang.String getAsset(); /** * <pre> * The Asset resource name of this discovery carousel card. * </pre> * * <code>optional string asset = 1;</code> * @return The bytes for asset. */ com.google.protobuf.ByteString getAssetBytes(); }
googleapis/google-cloud-java
1,026
java-shopping-merchant-accounts/proto-google-shopping-merchant-accounts-v1/src/main/java/com/google/shopping/merchant/accounts/v1/LocalListingManagementOrBuilder.java
/* * Copyright 2025 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. */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/shopping/merchant/accounts/v1/accountservices.proto // Protobuf Java Version: 3.25.8 package com.google.shopping.merchant.accounts.v1; public interface LocalListingManagementOrBuilder extends // @@protoc_insertion_point(interface_extends:google.shopping.merchant.accounts.v1.LocalListingManagement) com.google.protobuf.MessageOrBuilder {}
googleapis/google-cloud-java
1,031
java-storagebatchoperations/proto-google-cloud-storagebatchoperations-v1/src/main/java/com/google/cloud/storagebatchoperations/v1/CancelJobResponseOrBuilder.java
/* * Copyright 2025 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. */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/cloud/storagebatchoperations/v1/storage_batch_operations.proto // Protobuf Java Version: 3.25.8 package com.google.cloud.storagebatchoperations.v1; public interface CancelJobResponseOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.storagebatchoperations.v1.CancelJobResponse) com.google.protobuf.MessageOrBuilder {}
googlearchive/gwt-google-apis
1,107
search/search/src/com/google/gwt/search/client/DrawMode.java
/* * Copyright 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.gwt.search.client; import com.google.gwt.search.jsio.client.JSOpaque; /** * Used by {@link SearchControlOptions#setDrawMode(DrawMode)}. */ public enum DrawMode { /** * Specifies linear drawing mode. */ LINEAR("LINEAR"), /** * Specifies tabbed drawing mode. */ TABBED("TABBED"); private final JSOpaque value; private DrawMode(String mode) { value = new JSOpaque("$wnd.GSearchControl.DRAW_MODE_" + mode); } JSOpaque getValue() { return value; } }
hibernate/hibernate-ogm
1,081
core/src/main/java/org/hibernate/ogm/dialect/eventstate/impl/EventContextManagerInitiator.java
/* * Hibernate OGM, Domain model persistence for NoSQL datastores * * License: GNU Lesser General Public License (LGPL), version 2.1 or later * See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>. */ package org.hibernate.ogm.dialect.eventstate.impl; import java.util.Map; import org.hibernate.boot.registry.StandardServiceInitiator; import org.hibernate.service.spi.ServiceRegistryImplementor; /** * Contributes the {@link EventContextManager} service. * * @author Gunnar Morling */ @SuppressWarnings("rawtypes") public class EventContextManagerInitiator implements StandardServiceInitiator<EventContextManager> { public static final EventContextManagerInitiator INSTANCE = new EventContextManagerInitiator(); private EventContextManagerInitiator() { } @Override public Class<EventContextManager> getServiceInitiated() { return EventContextManager.class; } @Override public EventContextManager initiateService(Map configurationValues, ServiceRegistryImplementor registry) { return new EventContextManager(); } }
hibernate/hibernate-search
1,028
v5migrationhelper/engine/src/main/java/org/hibernate/search/query/dsl/sort/impl/ConnectedSortDistanceFieldAndReferenceContext.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.search.query.dsl.sort.impl; import org.hibernate.search.query.dsl.impl.QueryBuildingContext; import org.hibernate.search.query.dsl.sort.SortDistanceFieldAndReferenceContext; import org.apache.lucene.search.Sort; /** * @author Emmanuel Bernard emmanuel@hibernate.org */ public class ConnectedSortDistanceFieldAndReferenceContext extends ConnectedSortAdditionalSortFieldContext implements SortDistanceFieldAndReferenceContext { public ConnectedSortDistanceFieldAndReferenceContext(QueryBuildingContext queryContext, SortFieldStates states) { super( queryContext, states ); } @Override public SortDistanceFieldAndReferenceContext asc() { getStates().setAsc(); return this; } @Override public SortDistanceFieldAndReferenceContext desc() { getStates().setDesc(); return this; } @Override public Sort createSort() { getStates().closeSortField(); return getStates().createSort(); } }
hibernate/hibernate-search
1,046
mapper/pojo-base/src/main/java/org/hibernate/search/mapper/pojo/bridge/binding/impl/MarkerBindingContextImpl.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.search.mapper.pojo.bridge.binding.impl; import java.util.Map; import org.hibernate.search.engine.environment.bean.BeanResolver; import org.hibernate.search.mapper.pojo.bridge.binding.MarkerBindingContext; import org.hibernate.search.mapper.pojo.bridge.mapping.programmatic.MarkerBinder; import org.hibernate.search.mapper.pojo.logging.impl.MappingLog; public final class MarkerBindingContextImpl extends AbstractBindingContext implements MarkerBindingContext { private Object marker; public MarkerBindingContextImpl(BeanResolver beanResolver, Map<String, Object> params) { super( beanResolver, params ); } @Override public void marker(Object marker) { this.marker = marker; } public Object applyBinder(MarkerBinder binder) { // This call should set the partial binding binder.bind( this ); if ( marker == null ) { throw MappingLog.INSTANCE.missingMarkerForBinder( binder ); } return marker; } }
hibernate/hibernate-validator
1,060
engine/src/test/java/org/hibernate/validator/test/internal/engine/traversableresolver/BookBusinessRules.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.validator.test.internal.engine.traversableresolver; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import jakarta.validation.Constraint; import jakarta.validation.ConstraintValidator; import jakarta.validation.ConstraintValidatorContext; import jakarta.validation.Payload; @Constraint(validatedBy = { BookBusinessRules.BookBusinessRulesValidator.class }) @Documented @Target(ElementType.TYPE) @Retention(RetentionPolicy.RUNTIME) @interface BookBusinessRules { String message() default ""; Class<?>[] groups() default { }; Class<? extends Payload>[] payload() default { }; class BookBusinessRulesValidator implements ConstraintValidator<BookBusinessRules, Object> { @Override public boolean isValid(Object value, ConstraintValidatorContext context) { return true; } } }
hibernate/hibernate-validator
1,080
integrationtest/wildfly/src/test/java/org/hibernate/validator/integration/util/OxBerryConstraint.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.validator.integration.util; import static java.lang.annotation.ElementType.ANNOTATION_TYPE; 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.PARAMETER; import static java.lang.annotation.RetentionPolicy.RUNTIME; import java.lang.annotation.Documented; import java.lang.annotation.Retention; import java.lang.annotation.Target; import jakarta.validation.Constraint; import jakarta.validation.Payload; /** * @author Hardy Ferentschik */ @Documented @Constraint(validatedBy = { }) @Target({ METHOD, FIELD, ANNOTATION_TYPE, CONSTRUCTOR, PARAMETER }) @Retention(RUNTIME) public @interface OxBerryConstraint { String message() default "{org.hibernate.validator.integration.util.OxBerryConstraint.message}"; Class<?>[] groups() default { }; Class<? extends Payload>[] payload() default { }; }
openjdk/asmtools
1,145
test/java/org/openjdk/asmtools/lib/transform/ITestRunner.java
/* * Copyright (c) 2023, 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 org.openjdk.asmtools.lib.transform; public interface ITestRunner { void run(); }
openjdk/jdk8
1,124
langtools/test/com/sun/javadoc/testNewLanguageFeatures/pkg/TypeParameterSuperClass.java
/* * Copyright (c) 2003, 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 pkg; public class TypeParameterSuperClass<E extends String> {}
openjdk/jdk8
1,132
langtools/test/tools/javac/diags/examples/IntfAnnotationCantHaveTypeParams.java
/* * Copyright (c) 2010, 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. */ // key: compiler.err.intf.annotation.cant.have.type.params @interface X<T> { }
openjdk/jdk8
1,139
jdk/test/java/rmi/reliability/benchmark/bench/rmi/altroot/Node.java
/* * Copyright (c) 2000, 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. */ /* * */ import java.io.Serializable; public class Node implements Serializable { }
openjdk/jdk8
1,140
langtools/test/tools/javac/diags/examples/UnclosedStringLiteral.java
/* * Copyright (c) 2010, 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. */ // key: compiler.err.unclosed.str.lit class UnclosedStringLit { String s = "abc; }
openjdk/jdk8
1,141
langtools/test/tools/javac/diags/examples/IllegalUnicodeEscape.java
/* * Copyright (c) 2010, 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. */ // key: compiler.err.illegal.unicode.esc class IllegalUnicodeEscape { int i = \u; }
openjdk/jdk8
1,145
langtools/test/com/sun/javadoc/testGeneratedBy/pkg/MyClass.java
/* * Copyright (c) 2012, 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 pkg; import java.io.Serializable; public class MyClass implements Serializable { }
openjdk/jdk8
1,145
langtools/test/tools/javac/diags/examples/InvalidMethodDecl.java
/* * Copyright (c) 2010, 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. */ // key: compiler.err.invalid.meth.decl.ret.type.req class InvalidMethodDecl { m() { } }
openjdk/jdk8
1,147
langtools/test/tools/javac/diags/examples/CyclicInheritance.java
/* * Copyright (c) 2010, 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. */ // key: compiler.err.cyclic.inheritance class CyclicInheritance extends CyclicInheritance { }
openjdk/jdk8
1,167
langtools/test/tools/javac/T6234077.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. */ /* * @test * @bug 6234077 * @compile/fail T6234077.java */ @Deprecated /** @deprecated */ public class Foo { }
openjdk/jdk8
1,171
langtools/test/tools/jdeps/f/F.java
/* * Copyright (c) 2013, 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 f; public class F { public F() { // jdk internal API sun.misc.Unsafe.getUnsafe(); } }
openjdk/jdk8
1,173
langtools/test/tools/jdeps/g/G.java
/* * Copyright (c) 2013, 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 g; public class G { // Full JRE private static final boolean gui = java.beans.Beans.isGuiAvailable(); }
openjdk/jtreg
1,180
test/exitCodes/Fail.java
/* * Copyright (c) 1998, 2013, 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. */ /* * @test */ public class Fail { public static void main(String... args) { throw new Exception(); } }
apache/commons-io
1,141
src/test/java/org/apache/commons/io/function/IOIntStream.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.io.function; import java.util.stream.IntStream; /** * Placeholder for future possible development and makes sure we can extend IOBaseStream cleanly with proper generics. */ interface IOIntStream extends IOBaseStream<Integer, IOIntStream, IntStream> { // Placeholder for future possible development. }
apache/commons-rdf
1,112
commons-rdf-jsonld-java/src/main/java/org/apache/commons/rdf/jsonldjava/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. */ /** * Integration with jsonld-java * * @see org.apache.commons.rdf.jsonldjava.JsonLdRDF * @see org.apache.commons.rdf.jsonldjava.JsonLdGraph * @see org.apache.commons.rdf.jsonldjava.JsonLdUnionGraph * @see org.apache.commons.rdf.jsonldjava.JsonLdDataset */ package org.apache.commons.rdf.jsonldjava;
apache/cxf
1,098
rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/fortest/aegis/Mammal.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.cxf.javascript.fortest.aegis; /** * */ public class Mammal { private String name; public Mammal() { name = "shrew"; } public String getName() { return name; } public void setName(String name) { this.name = name; } }
apache/cxf
1,111
systests/uncategorized/src/test/java/org/apache/cxf/systest/type_substitution/AppleFinder.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. */ // START SNIPPET: service package org.apache.cxf.systest.type_substitution; import java.util.List; import jakarta.jws.WebService; import jakarta.xml.bind.annotation.XmlSeeAlso; @WebService @XmlSeeAlso({ Apple.class, Fuji.class }) public interface AppleFinder { List<Apple> getApple(String appType); }
apache/datafusion-comet
1,128
common/src/main/java/org/apache/comet/CometRuntimeException.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.comet; /** The parent class for all Comet runtime exceptions */ public class CometRuntimeException extends RuntimeException { public CometRuntimeException(String message) { super(message); } public CometRuntimeException(String message, Throwable cause) { super(message, cause); } }
apache/deltaspike
1,077
deltaspike/modules/test-control/impl/src/test/java/org/apache/deltaspike/test/testcontrol/uc019/DefaultTestService.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.testcontrol.uc019; import jakarta.enterprise.context.ApplicationScoped; @ApplicationScoped public class DefaultTestService implements TestService { @Override public String getValue() { return "default-result"; } }
apache/deltaspike
1,102
deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/config/view/DefaultErrorView.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.core.api.config.view; /** * Abstract class which marks an error view. * * It's an abstract class instead of an interface, because it can be used for navigation (which is restricted to * classes). */ public abstract class DefaultErrorView implements ViewConfig { }
apache/druid
1,120
processing/src/main/java/org/apache/druid/segment/data/ColumnarIntsSerializer.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.segment.data; import org.apache.druid.segment.serde.Serializer; import java.io.IOException; /** * Serializer that produces either {@link ColumnarInts} or {@link ColumnarMultiInts}. */ public interface ColumnarIntsSerializer extends Serializer { void open() throws IOException; }
apache/druid
1,132
server/src/main/java/org/apache/druid/rpc/ServiceClosedException.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.rpc; /** * Returned by {@link ServiceClient#asyncRequest} when a request has failed because the service is closed. */ public class ServiceClosedException extends RpcException { public ServiceClosedException(final String serviceName) { super("Service [%s] is closed", serviceName); } }
apache/dubbo-samples
1,088
4-governance/dubbo-samples-zipkin/src/main/java/org/apache/dubbo/samples/service/hello/HelloServiceImpl.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.service.hello; import org.apache.dubbo.samples.api.HelloService; public class HelloServiceImpl implements HelloService { @Override public String hello(String message) { return "hello, " + message; } }
apache/dubbo-spi-extensions
1,059
dubbo-serialization-extensions/dubbo-serialization-kryo/src/test/java/org/apache/dubbo/common/serialize/kryo/KyroSerializationTest.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.common.serialize.kryo; import org.apache.dubbo.common.serialize.base.AbstractSerializationTest; public class KyroSerializationTest extends AbstractSerializationTest { { serialization = new KryoSerialization(); } }
apache/eagle
1,078
eagle-core/eagle-alert-parent/eagle-alert/alert-engine/src/main/java/org/apache/eagle/alert/engine/publisher/AlertStreamFilter.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 * <p> * http://www.apache.org/licenses/LICENSE-2.0 * <p> * 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.eagle.alert.engine.publisher; import org.apache.eagle.alert.engine.model.AlertStreamEvent; public interface AlertStreamFilter { /** * Filter Stream Event, if skipped, return null. */ AlertStreamEvent filter(AlertStreamEvent event); }
apache/eagle
1,107
eagle-core/eagle-metric/src/main/java/org/apache/eagle/metric/reportor/EagleMetricListener.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.eagle.metric.reportor; import java.util.List; public interface EagleMetricListener { /** * The method should be called in thread-safe mode. * * @param metrics */ void onMetricFlushed(List<EagleMetric> metrics); }
apache/empire-db
1,134
empire-db/src/main/java/org/apache/empire/data/Entity.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.empire.data; import java.util.List; /** * EntityType * Defines an entity such as a table or view */ public interface Entity { String getEntityName(); List<? extends Column> getColumns(); Column getColumn(String name); Column[] getKeyColumns(); Class<?> getBeanType(); }
apache/eventmesh
1,067
eventmesh-connectors/eventmesh-connector-mongodb/src/main/java/org/apache/eventmesh/connector/mongodb/config/MongodbServerConfig.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.config; import org.apache.eventmesh.common.config.connector.Config; import lombok.Data; @Data public class MongodbServerConfig extends Config { private boolean sourceEnable; private boolean sinkEnable; }
apache/felix-dev
1,038
ipojo/manipulator/manipulator-it/ipojo-manipulator-manipulation-metadata-test/src/main/java/org/apache/felix/ipojo/runtime/core/services/CheckService.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.services; import java.util.Properties; public interface CheckService { public static final String foo = "foo"; public boolean check(); public Properties getProps(); }
apache/felix-dev
1,102
scr/src/test/java/org/apache/felix/scr/integration/components/felix6274_2/Component.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.scr.integration.components.felix6274_2; import org.osgi.service.log.LogService; public class Component { LogService logger; @SuppressWarnings("deprecation") void activate() { logger.log(LogService.LOG_INFO, "Hello from felix6274_2"); } }
apache/fineract
1,071
fineract-e2e-tests-core/src/test/java/org/apache/fineract/test/messaging/event/assetexternalization/LoanOwnershipTransferEvent.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.assetexternalization; public class LoanOwnershipTransferEvent extends AbstractLoanOwnershipTransferEvent { @Override public String getEventName() { return "LoanOwnershipTransferBusinessEvent"; } }
apache/fineract
1,106
fineract-provider/src/main/java/org/apache/fineract/portfolio/address/domain/AddressRepository.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.address.domain; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.JpaSpecificationExecutor; public interface AddressRepository extends JpaRepository<Address, Long>, JpaSpecificationExecutor<Address> { }
apache/flink
1,100
flink-table/flink-table-common/src/main/java/org/apache/flink/table/types/logical/TimestampKind.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.types.logical; import org.apache.flink.annotation.Internal; /** * Internal timestamp kind for attaching time attribute metadata to timestamps with or without a * time zone. */ @Internal public enum TimestampKind { REGULAR, ROWTIME, PROCTIME }
apache/flink
1,110
flink-table/flink-table-common/src/main/java/org/apache/flink/table/catalog/SchemaResolver.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.catalog; import org.apache.flink.annotation.PublicEvolving; import org.apache.flink.table.api.Schema; /** Resolves a {@link Schema} to a validated {@link ResolvedSchema}. */ @PublicEvolving public interface SchemaResolver { ResolvedSchema resolve(Schema schema); }
apache/flink
1,116
flink-runtime/src/test/java/org/apache/flink/runtime/rest/util/NoOpFatalErrorHandler.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.runtime.rest.util; import org.apache.flink.runtime.rpc.FatalErrorHandler; /** {@link FatalErrorHandler} which does nothing. */ public enum NoOpFatalErrorHandler implements FatalErrorHandler { INSTANCE; @Override public void onFatalError(final Throwable exception) {} }
apache/fluss
1,114
fluss-common/src/main/java/org/apache/fluss/exception/RetriableAuthenticationException.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; /** * This exception is thrown if authentication fails with a retriable error. * * @since 0.7 */ public class RetriableAuthenticationException extends AuthenticationException { public RetriableAuthenticationException(String message) { super(message); } }
apache/fory
1,123
java/fory-core/src/test/java/org/apache/fory/collection/Tuple2Test.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.fory.collection; import static org.testng.Assert.*; import org.testng.annotations.Test; public class Tuple2Test { @Test public void testEquals() { assertEquals(Tuple2.of(1, "a"), Tuple2.of(1, "a")); assertEquals(Tuple2.of(1, "a").hashCode(), Tuple2.of(1, "a").hashCode()); } }
apache/fory
1,131
java/fory-core/src/main/java/org/apache/fory/annotation/CodegenInvoke.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.fory.annotation; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; /** * An annotation to mark a method will be invoked by generated method. This annotation is used for * documentation only. */ @Retention(RetentionPolicy.SOURCE) public @interface CodegenInvoke {}