repo_id
stringclasses
875 values
size
int64
974
38.9k
file_path
stringlengths
10
308
content
stringlengths
974
38.9k
apache/incubator-kie-optaplanner
1,040
core/optaplanner-core-impl/src/main/java/org/optaplanner/core/impl/heuristic/selector/list/DestinationSelector.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.optaplanner.core.impl.heuristic.selector.list; import org.optaplanner.core.impl.heuristic.selector.IterableSelector; public interface DestinationSelector<Solution_> extends IterableSelector<Solution_, ElementRef> { }
apache/incubator-seata
1,059
integration-tx-api/src/test/java/org/apache/seata/integration/tx/api/interceptor/parser/Business.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.seata.integration.tx.api.interceptor.parser; /** * The interface Business. */ public interface Business { /** * Do biz string. * * @param msg the msg * @return the string */ String doBiz(String msg); }
apache/inlong
1,040
inlong-sort-standalone/sort-standalone-common/src/main/java/org/apache/inlong/sort/standalone/config/loader/v2/SortConfigLoader.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.inlong.sort.standalone.config.loader.v2; import org.apache.inlong.common.pojo.sort.SortConfig; import org.apache.flume.conf.Configurable; public interface SortConfigLoader extends Configurable { SortConfig load(); }
apache/inlong
1,049
inlong-tubemq/tubemq-manager/src/main/java/org/apache/inlong/tubemq/manager/controller/group/result/ConsumerInfoRes.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.inlong.tubemq.manager.controller.group.result; import lombok.Data; import java.util.List; @Data public class ConsumerInfoRes { private String consumeGroup; private List<String> topicSet; private Double consumerNum; }
apache/inlong
1,082
inlong-common/src/main/java/org/apache/inlong/common/pojo/sort/node/HttpNodeConfig.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.inlong.common.pojo.sort.node; import lombok.Data; @Data public class HttpNodeConfig extends NodeConfig { private String baseUrl; private Boolean enableCredential; private String username; private String password; private Integer maxConnect; }
apache/iotdb
1,070
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/schema/node/utils/IMNodeIterator.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.iotdb.commons.schema.node.utils; import org.apache.iotdb.commons.schema.node.IMNode; import java.util.Iterator; public interface IMNodeIterator<N extends IMNode<?>> extends Iterator<N> { void skipTemplateChildren(); void close(); }
apache/iotdb
1,074
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/exception/ainode/ModelNotFoundException.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.iotdb.db.exception.ainode; import org.apache.iotdb.rpc.TSStatusCode; public class ModelNotFoundException extends ModelException { public ModelNotFoundException(String message) { super(message, TSStatusCode.MODEL_NOT_FOUND_ERROR); } }
apache/jackrabbit-oak
1,064
oak-run-commons/src/main/java/org/apache/jackrabbit/oak/run/cli/FileStoreTarBuilderCustomizer.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.jackrabbit.oak.run.cli; import java.io.IOException; import org.apache.jackrabbit.oak.segment.file.FileStoreBuilder; public interface FileStoreTarBuilderCustomizer { void customize(FileStoreBuilder builder) throws IOException; }
apache/jackrabbit-oak
1,071
oak-segment-tar/src/test/java/org/apache/jackrabbit/oak/segment/LongIdMappingBlobStore.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.jackrabbit.oak.segment; public class LongIdMappingBlobStore extends IdMappingBlobStore { private static int next; @Override protected String generateId() { return "0".repeat(Segment.BLOB_ID_SMALL_LIMIT * 20) + next++; } }
apache/jackrabbit
1,075
jackrabbit-core/src/main/java/org/apache/jackrabbit/core/xml/DefaultProtectedNodeImporter.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.jackrabbit.core.xml; /** * Default implementation that isn't able to handle any protected nodes. */ public class DefaultProtectedNodeImporter extends DefaultProtectedItemImporter { public DefaultProtectedNodeImporter() { super(); } }
apache/jena
1,082
jena-shacl/src/main/java/org/apache/jena/shacl/validation/event/ValidationLifecycleEvent.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.jena.shacl.validation.event; /** * Tagging interface for all events relating to the 'lifecyle' of a SHACL * validation (validation started/finished, focus nodes determined, etc.) */ public interface ValidationLifecycleEvent extends ValidationEvent { }
apache/jena
1,097
jena-core/src/test/java/org/apache/jena/util/junit/ManifestOldItemHandler.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.jena.util.junit; import org.apache.jena.rdf.model.Resource; public interface ManifestOldItemHandler { /** Handle an item in a manifest */ public boolean processManifestItem(Resource manifest, Resource item, String testName, Resource action, Resource result); }
apache/jspwiki
1,100
jspwiki-main/src/main/java/org/apache/wiki/providers/FastSearch.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.wiki.providers; /** * If a provider implements this interface, then CachingProvider * will never attempt to search on its own; it will always pass any searches * through to the actual provider. * * @since 2.1.57 */ public interface FastSearch { }
apache/kafka
1,064
streams/src/test/java/org/apache/kafka/streams/state/internals/RocksDBTimeOrderedSessionStoreWithIndexTest.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.kafka.streams.state.internals; public class RocksDBTimeOrderedSessionStoreWithIndexTest extends AbstractSessionBytesStoreTest { @Override StoreType storeType() { return StoreType.RocksDBTimeOrderedSessionStoreWithIndex; } }
apache/kafka
1,095
metadata/src/main/java/org/apache/kafka/metadata/placement/UsableBroker.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.kafka.metadata.placement; import org.apache.kafka.common.annotation.InterfaceStability; import java.util.Optional; /** * A broker where a replica can be placed. */ @InterfaceStability.Unstable public record UsableBroker(int id, Optional<String> rack, boolean fenced) { }
apache/karaf
1,078
features/core/src/main/java/org/apache/karaf/features/internal/download/StreamProvider.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.karaf.features.internal.download; import java.io.File; import java.io.IOException; import java.io.InputStream; public interface StreamProvider { String getUrl(); File getFile() throws IOException; InputStream open() throws IOException; }
apache/karaf
1,087
shell/commands/src/main/java/org/apache/karaf/shell/commands/info/InfoProvider.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.karaf.shell.commands.info; import java.util.Properties; /** * A bundle can publish a service with this interface to offer some informations for the shell:info command */ public interface InfoProvider { String getName(); Properties getProperties(); }
apache/linkis
1,051
linkis-public-enhancements/linkis-configuration/src/main/java/org/apache/linkis/configuration/LinkisConfigurationApp.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.linkis.configuration; import org.apache.linkis.LinkisBaseServerApp; public class LinkisConfigurationApp { public static void main(String[] args) throws ReflectiveOperationException { LinkisBaseServerApp.main(args); } }
apache/linkis
1,058
linkis-public-enhancements/linkis-cs-server/src/main/java/org/apache/linkis/cs/server/scheduler/CsScheduler.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.linkis.cs.server.scheduler; import org.apache.linkis.cs.server.service.Service; public interface CsScheduler { void addService(Service service); Service[] getServices(); void submit(HttpJob job) throws InterruptedException; }
apache/linkis
1,063
linkis-engineconn-plugins/repl/src/main/java/org/apache/linkis/engineplugin/repl/exception/ReplException.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.linkis.engineplugin.repl.exception; import org.apache.linkis.common.exception.ErrorException; public class ReplException extends ErrorException { public ReplException(int errorCode, String message) { super(errorCode, message); } }
apache/logging-log4j2
1,075
log4j-core/src/main/java/org/apache/logging/log4j/core/appender/rewrite/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. */ /** * Apache Flume Appender. Requires the user specifically include Flume and its dependencies. */ @Export @Version("2.20.1") package org.apache.logging.log4j.core.appender.rewrite; import org.osgi.annotation.bundle.Export; import org.osgi.annotation.versioning.Version;
apache/logging-log4j2
1,075
log4j-core/src/main/java/org/apache/logging/log4j/core/appender/routing/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. */ /** * Apache Flume Appender. Requires the user specifically include Flume and its dependencies. */ @Export @Version("2.26.0") package org.apache.logging.log4j.core.appender.routing; import org.osgi.annotation.bundle.Export; import org.osgi.annotation.versioning.Version;
apache/lucene
1,075
lucene/queryparser/src/java/org/apache/lucene/queryparser/flexible/core/util/StringUtils.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.lucene.queryparser.flexible.core.util; /** String manipulation routines */ public final class StringUtils { public static String toString(Object obj) { if (obj != null) { return obj.toString(); } else { return null; } } }
apache/lucene
1,084
lucene/luke/src/java/org/apache/lucene/luke/app/desktop/util/inifile/IniFileWriter.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.lucene.luke.app.desktop.util.inifile; import java.io.IOException; import java.nio.file.Path; import java.util.Map; /** ini files writer */ public interface IniFileWriter { void writeSections(Path path, Map<String, OptionMap> sections) throws IOException; }
apache/marmotta
1,088
commons/marmotta-commons/src/ext/java/javolution/util/function/Function.java
/* * Javolution - Java(TM) Solution for Real-Time and Embedded Systems * Copyright (C) 2012 - Javolution (http://javolution.org/) * All rights reserved. * * Permission to use, copy, modify, and distribute this software is * freely granted, provided that this notice is preserved. */ package javolution.util.function; /** * <p> A function that perform some operation and returns the result of * that operation.</p> * * @param <T> the type of the input parameter of the apply operation. * @param <R> the type of the result of the apply operation. * * @author <a href="mailto:jean-marie@dautelle.com">Jean-Marie Dautelle</a> * @version 6.0, July 21, 2013 * @see <a href="http://en.wikipedia.org/wiki/Function_(computer_science)">Wikipedia: Function<a> */ public interface Function<T, R> { /** * Returns the result of applying this function to the specified parameter. * * @param param the parameter object on which the function is performed. * @return the result of the function. */ R apply(T param); }
apache/maven-plugins
1,079
maven-jmod-plugin/src/it/base-config/src/main/java/myproject/HelloWorld.java
package myproject; /* * 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. */ /** * The classic Hello World App. */ public class HelloWorld { /** * Main method. * * @param args Not used */ public static void main( String[] args ) { System.out.println( "Hello World from JDK 9" ); } }
apache/maven
1,066
compat/maven-plugin-api/src/main/java/org/apache/maven/plugin/descriptor/DuplicateParameterException.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.maven.plugin.descriptor; /** * DuplicateParameterException */ public class DuplicateParameterException extends InvalidPluginDescriptorException { public DuplicateParameterException(String message) { super(message); } }
apache/mina-sshd
1,081
sshd-sftp/src/main/java/org/apache/sshd/sftp/server/SftpFileSystemAccessorManager.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.sshd.sftp.server; /** * @author <a href="mailto:dev@mina.apache.org">Apache MINA SSHD Project</a> */ public interface SftpFileSystemAccessorManager extends SftpFileSystemAccessorProvider { void setFileSystemAccessor(SftpFileSystemAccessor accessor); }
apache/nifi-minifi
1,038
minifi-toolkit/minifi-toolkit-configuration/src/main/java/org/apache/nifi/minifi/toolkit/configuration/PathOutputStreamFactory.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.nifi.minifi.toolkit.configuration; import java.io.FileNotFoundException; import java.io.OutputStream; public interface PathOutputStreamFactory { OutputStream create(String path) throws FileNotFoundException; }
apache/nifi
1,072
nifi-extension-bundles/nifi-cdc/nifi-cdc-api/src/main/java/org/apache/nifi/cdc/event/RowEventInfo.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.nifi.cdc.event; import java.util.List; /** * An interface corresponding to row-level info from events on tabular data structures. */ public interface RowEventInfo<RowEventDataType> extends TableEventInfo { List<RowEventDataType> getRows(); }
apache/nifi
1,075
nifi-toolkit/nifi-toolkit-cli/src/main/java/org/apache/nifi/toolkit/cli/api/CommandException.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.nifi.toolkit.cli.api; public class CommandException extends Exception { public CommandException(String message) { super(message); } public CommandException(String message, Throwable cause) { super(message, cause); } }
apache/olingo-odata4
1,065
lib/server-core/src/main/java/org/apache/olingo/server/core/uri/queryoption/CustomQueryOptionImpl.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.olingo.server.core.uri.queryoption; import org.apache.olingo.server.api.uri.queryoption.CustomQueryOption; public class CustomQueryOptionImpl extends QueryOptionImpl implements CustomQueryOption { // No additional methods needed for now. }
apache/openjpa
1,070
openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/proxy/delayed/IMember.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.openjpa.persistence.proxy.delayed; import java.util.Collection; public interface IMember { void setName(String name); String getName(); void setAccounts(Collection<IAccount> accounts); Collection<IAccount> getAccounts(); }
apache/openwebbeans
1,076
webbeans-impl/src/test/java/org/apache/webbeans/test/proxy/beans/ConversationBean.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.webbeans.test.proxy.beans; import jakarta.enterprise.context.ConversationScoped; import java.io.Serializable; /** * To test the proxy for conversation scoped beans. */ @ConversationScoped public class ConversationBean implements Serializable { }
apache/paimon
1,085
paimon-arrow/src/main/java/org/apache/paimon/arrow/writer/ArrowFieldWriterFactory.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.paimon.arrow.writer; import org.apache.arrow.vector.FieldVector; /** Factory to create {@link ArrowFieldWriter}. */ @FunctionalInterface public interface ArrowFieldWriterFactory { ArrowFieldWriter create(FieldVector fieldVector, boolean isNullable); }
apache/pdfbox
1,099
pdfbox/src/main/java/org/apache/pdfbox/pdmodel/fixup/AbstractFixup.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.pdfbox.pdmodel.fixup; import org.apache.pdfbox.pdmodel.PDDocument; public abstract class AbstractFixup implements PDDocumentFixup { protected final PDDocument document; protected AbstractFixup(PDDocument document) { this.document = document; } }
apache/pig
1,132
src/org/apache/pig/builtin/SQRT.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.pig.builtin; /** * SQRT implements a binding to the Java function * {@link java.lang.Math#sqrt(double) Math.sqrt(double)}. * Given a single data atom it Returns the square root of the argument. * */ public class SQRT extends DoubleBase{ Double compute(Double input){ return Math.sqrt(input); } }
apache/plc4x
1,094
plc4j/spi/src/main/java/org/apache/plc4x/java/spi/values/PlcValueHandler.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.plc4x.java.spi.values; import org.apache.plc4x.java.api.model.PlcTag; import org.apache.plc4x.java.api.value.PlcValue; public interface PlcValueHandler { PlcValue newPlcValue(PlcTag tag, Object value); PlcValue newPlcValue(PlcTag tag, Object[] values); }
apache/poi
1,103
poi-scratchpad/src/main/java/org/apache/poi/hwpf/usermodel/ObjectsPool.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.poi.hwpf.usermodel; import org.apache.poi.poifs.filesystem.Entry; public interface ObjectsPool { public Entry getObjectById( String objId ); }
apache/polygene-java
1,086
core/testsupport/src/main/java/org/apache/polygene/test/model/Protocol.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.polygene.test.model; import org.apache.polygene.api.property.Property; import org.apache.polygene.api.value.ValueComposite; /** * JAVADOC Add JavaDoc. */ public interface Protocol extends ValueComposite { Property<String> value(); }
apache/pulsar
1,075
pulsar-client-admin-api/src/main/java/org/apache/pulsar/common/policies/data/ErrorData.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.pulsar.common.policies.data; /** * Class holding data in case of error responses. */ public class ErrorData { public String reason; public ErrorData() { } public ErrorData(String reason) { this.reason = reason; } }
apache/qpid-broker-j
1,066
broker-core/src/test/java/org/apache/qpid/server/model/testmodels/hierarchy/TestRechargeable.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.qpid.server.model.testmodels.hierarchy; import org.apache.qpid.server.model.ManagedAnnotation; import org.apache.qpid.server.model.ManagedInterface; @ManagedAnnotation public interface TestRechargeable extends ManagedInterface { }
apache/qpid-broker-j
1,079
broker-core/src/main/java/org/apache/qpid/server/virtualhost/LinkRegistryFactory.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.qpid.server.virtualhost; import org.apache.qpid.server.model.NamedAddressSpace; import org.apache.qpid.server.plugin.Pluggable; public interface LinkRegistryFactory extends Pluggable { LinkRegistryModel create(NamedAddressSpace addressSpace); }
apache/qpid-broker-j
1,088
perftests/src/main/java/org/apache/qpid/disttest/client/Participant.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.qpid.disttest.client; public interface Participant { void startTest(String registeredClientName, ResultReporter resultReporter) throws Exception; void stopTest(); void releaseResources(); String getName(); void startDataCollection(); }
apache/reef
1,087
lang/java/reef-tang/tang/src/main/java/org/apache/reef/tang/types/ConstructorDef.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.tang.types; public interface ConstructorDef<T> extends Comparable<ConstructorDef<?>> { String getClassName(); ConstructorArg[] getArgs(); boolean isMoreSpecificThan(ConstructorDef<?> def); boolean takesParameters(ClassNode<?>[] paramTypes); }
apache/rocketmq-eventbridge
1,053
adapter/runtime/src/main/java/org/apache/rocketmq/eventbridge/adapter/runtime/trace/TraceFactory.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.adapter.runtime.trace; import java.util.Map; public class TraceFactory { public void createSpan(Map<String,String> content){ } public void finishSpan(Map<String,String> content){ } }
apache/rocketmq-externals
1,044
rocketmq-serializer/rocketmq-serializer-core/src/main/java/org/apache/rocketmq/serializer/RocketMQDeserializer.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.serializer; public interface RocketMQDeserializer<T> { /** * Deserializing bytes to object. * @param bytes bytes need deserializing * @return object */ T deserialize(byte[] bytes); }
apache/royale-compiler
1,055
compiler-common/src/main/java/org/apache/royale/compiler/internal/config/localization/ILocalizedText.java
/* * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ package org.apache.royale.compiler.internal.config.localization; import java.util.Map; /** * Defines the API for formatting localized text. */ public interface ILocalizedText { String format(Map<String, Object> parameters); }
apache/royale-compiler
1,074
compiler-jx/src/main/java/org/apache/royale/compiler/codegen/mxml/js/IMXMLJSEmitter.java
/* * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ package org.apache.royale.compiler.codegen.mxml.js; import org.apache.royale.compiler.codegen.js.IMappingEmitter; import org.apache.royale.compiler.codegen.mxml.IMXMLEmitter; public interface IMXMLJSEmitter extends IMXMLEmitter, IMappingEmitter { }
apache/rya
1,056
extras/rya.pcj.fluo/rya.pcj.functions.geo/src/main/java/org/apache/rya/indexing/pcj/functions/geo/IntersectionRdf4J.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.rya.indexing.pcj.functions.geo; public class IntersectionRdf4J extends FunctionAdapter { public IntersectionRdf4J() { super(new org.eclipse.rdf4j.query.algebra.evaluation.function.geosparql.Intersection()); } }
apache/rya
1,056
extras/rya.pcj.fluo/rya.pcj.functions.geo/src/main/java/org/apache/rya/indexing/pcj/functions/geo/SfIntersectsRdf4J.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.rya.indexing.pcj.functions.geo; public class SfIntersectsRdf4J extends FunctionAdapter { public SfIntersectsRdf4J() { super(new org.eclipse.rdf4j.query.algebra.evaluation.function.geosparql.SfIntersects()); } }
apache/rya
1,073
extras/indexing/src/main/java/org/apache/rya/indexing/IndexPlanValidator/IndexTupleGenerator.java
package org.apache.rya.indexing.IndexPlanValidator; /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ import java.util.Iterator; import org.eclipse.rdf4j.query.algebra.TupleExpr; public interface IndexTupleGenerator { public Iterator<TupleExpr> getPlans(Iterator<TupleExpr> indexPlans); }
apache/seatunnel-web
1,055
seatunnel-server/seatunnel-app/src/main/java/org/apache/seatunnel/app/domain/dto/job/ScriptJobApplyDto.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.seatunnel.app.domain.dto.job; import lombok.Builder; import lombok.Data; @Data @Builder public class ScriptJobApplyDto { private int scriptId; private int schedulerConfigId; private long jobId; private int userId; }
apache/seatunnel-web
1,065
seatunnel-server/seatunnel-app/src/main/java/org/apache/seatunnel/app/dal/mapper/RoleMapper.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.seatunnel.app.dal.mapper; import org.apache.seatunnel.app.dal.entity.Role; import org.apache.ibatis.annotations.Param; public interface RoleMapper { int insert(Role record); Role selectByRole(@Param("roleName") String roleName); }
apache/seatunnel
1,032
seatunnel-connectors-v2/connector-typesense/src/main/java/org/apache/seatunnel/connectors/seatunnel/typesense/state/TypesenseCommitInfo.java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.seatunnel.connectors.seatunnel.typesense.state; import java.io.Serializable; public class TypesenseCommitInfo implements Serializable { private static final long serialVersionUID = -294402070211638237L; }
apache/sedona
1,083
spark/common/src/main/java/org/apache/sedona/sql/datasources/osmpbf/model/OsmNode.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.sedona.sql.datasources.osmpbf.model; import java.util.HashMap; public class OsmNode extends OSMEntity { public OsmNode(long id, double latitude, double longitude, HashMap<String, String> tags) { super(id, latitude, longitude, tags, "node"); } }
apache/servicecomb-java-chassis
1,044
handlers/handler-flowcontrol-qps/src/main/java/org/apache/servicecomb/qps/strategy/TokenBucketStrategy.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.qps.strategy; public class TokenBucketStrategy extends LeakyBucketStrategy { private static final String STRATEGY_NAME = "TokenBucket"; @Override public String name() { return STRATEGY_NAME; } }
apache/shardingsphere
1,029
kernel/data-pipeline/core/src/main/java/org/apache/shardingsphere/data/pipeline/core/job/engine/cleaner/PipelineJobRunnerCleaner.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.data.pipeline.core.job.engine.cleaner; /** * Pipeline job runner cleaner. */ public interface PipelineJobRunnerCleaner { /** * Clean pipeline job. */ void clean(); }
apache/shardingsphere
1,045
parser/distsql/statement/src/main/java/org/apache/shardingsphere/distsql/statement/type/rql/rule/RuleQueryStatement.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.distsql.statement.type.rql.rule; import org.apache.shardingsphere.distsql.statement.type.rql.RQLStatement; /** * Rule query statement. */ public abstract class RuleQueryStatement extends RQLStatement { }
apache/shindig
1,072
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleAdjacencyContentRewriter.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.shindig.gadgets.rewrite; /** * Merges adjacent style tags. * * @since 2.0.0 */ public class StyleAdjacencyContentRewriter extends DomWalker.Rewriter { public StyleAdjacencyContentRewriter() { super(new StyleAdjacencyVisitor()); } }
apache/shiro
1,092
core/src/test/java/org/apache/shiro/authz/HostUnauthorizedExceptionTest.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.shiro.authz; import org.apache.shiro.ExceptionTest; /** * @since Jun 10, 2008 4:04:38 PM */ public class HostUnauthorizedExceptionTest extends ExceptionTest { protected Class getExceptionClass() { return HostUnauthorizedException.class; } }
apache/storm
1,112
storm-client/src/jvm/org/apache/storm/topology/BoltDeclarer.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.storm.topology; /** * BoltDeclarer includes grouping APIs for storm topology. * * @see <a href="https://storm.apache.org/documentation/Concepts.html">Concepts -Stream groupings-</a> */ public interface BoltDeclarer extends InputDeclarer<BoltDeclarer>, ComponentConfigurationDeclarer<BoltDeclarer> { }
apache/streampipes
1,059
streampipes-client-api/src/main/java/org/apache/streampipes/client/api/constants/InputStreamIndex.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.client.api.constants; public enum InputStreamIndex { FIRST(0), SECOND(1); private Integer index; InputStreamIndex(Integer index) { this.index = index; } public Integer toIndex() { return index; } }
apache/struts
1,106
core/src/main/java/org/apache/struts2/FileManagerFactory.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.struts2; import org.apache.struts2.util.fs.DefaultFileManager; /** * Factory that creates FileManager, default to {@link DefaultFileManager} */ public interface FileManagerFactory { void setReloadingConfigs(String reloadingConfigs); FileManager getFileManager(); }
apache/syncope
1,062
core/persistence-jpa/src/main/java/org/apache/syncope/core/persistence/jpa/dao/repo/AnyTypeClassRepoExt.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.jpa.dao.repo; import org.apache.syncope.core.persistence.api.entity.AnyTypeClass; public interface AnyTypeClassRepoExt { AnyTypeClass save(AnyTypeClass anyTypeClass); void deleteById(String key); }
apache/syncope
1,062
core/persistence-jpa/src/main/java/org/apache/syncope/core/persistence/jpa/dao/repo/NotificationRepoExt.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.jpa.dao.repo; import org.apache.syncope.core.persistence.api.entity.Notification; public interface NotificationRepoExt { Notification save(Notification notification); void deleteById(String key); }
apache/syncope
1,064
client/idrepo/console/src/main/java/org/apache/syncope/client/console/wizards/any/UserFormFinalizer.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.client.console.wizards.any; public interface UserFormFinalizer { default void beforeUpdate(String userKey) { // nothing to do; } default void afterUpdate(String userKey) { // nothing to do; } }
apache/tomee
1,071
container/openejb-core/src/main/java/org/apache/openejb/util/proxy/BeanContextInvocationHandler.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.util.proxy; import org.apache.openejb.BeanContext; import java.lang.reflect.InvocationHandler; /** * @version $Rev$ $Date$ */ public interface BeanContextInvocationHandler extends InvocationHandler { BeanContext getBeanContext(); }
apache/tomee
1,073
itests/openejb-itests-client/src/main/java/org/apache/openejb/test/servlet/EjbServletTests.java
/** * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.openejb.test.servlet; public class EjbServletTests extends ServletTestClient { public EjbServletTests() { super("EjbServlet"); } public void test01_invokeBusinessMethod() { invoke("invokeBusinessMethod"); } }
apache/tomee
1,086
examples/cloud-tomee-azure/src/main/java/org/superbiz/echo/EchoResource.java
package org.superbiz.echo; /** * 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. */ import jakarta.ws.rs.GET; import jakarta.ws.rs.Path; import jakarta.ws.rs.PathParam; @Path("echo") public class EchoResource { @GET @Path("{echo}") public String echo(@PathParam("echo") final String echo) { return echo; } }
apache/uniffle
1,093
server/src/test/java/org/apache/uniffle/server/UnHealthyMockChecker.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.server; public class UnHealthyMockChecker extends Checker { @SuppressWarnings("checkstyle:RedundantModifier") public UnHealthyMockChecker(ShuffleServerConf conf) { super(conf); } @Override public boolean checkIsHealthy() { return false; } }
apache/usergrid
1,076
stack/services/src/main/java/org/apache/usergrid/services/notifications/ConnectionException.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.usergrid.services.notifications; import org.springframework.core.NestedCheckedException; public class ConnectionException extends NestedCheckedException { public ConnectionException(String msg, Throwable cause) { super(msg, cause); } }
apache/wicket
1,096
wicket-core-tests/src/test/java/org/apache/wicket/MyPage5.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; import org.apache.wicket.markup.html.WebPage; /** * Dummy Page with PageParameter constructor and default constructor */ public class MyPage5 extends WebPage { private static final long serialVersionUID = 1L; /** * Construct. */ public MyPage5() { } }
google/copybara
1,104
java/com/google/copybara/credentials/CredentialIssuer.java
/* * Copyright (C) 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. */ package com.google.copybara.credentials; import com.google.common.collect.ImmutableSetMultimap; import net.starlark.java.eval.StarlarkValue; /** * An object able to mint credentials. The issuer should handle caching etc. */ public interface CredentialIssuer extends StarlarkValue { /** * Issue a Credential to be used by an endpoint */ Credential issue() throws CredentialIssuingException; /** * Metadata describing this issuer. */ ImmutableSetMultimap<String, String> describe(); }
google/graphicsfuzz
1,084
reducer/src/main/java/com/graphicsfuzz/reducer/reductionopportunities/Util.java
/* * Copyright 2018 The GraphicsFuzz 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 * * 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.graphicsfuzz.reducer.reductionopportunities; import com.graphicsfuzz.common.ast.stmt.DeclarationStmt; import com.graphicsfuzz.util.Constants; class Util { static boolean isStructifiedDeclaration(DeclarationStmt declarationStmt) { return declarationStmt.getVariablesDeclaration().getNumDecls() == 1 && declarationStmt.getVariablesDeclaration().getDeclInfo(0).getName() .startsWith(Constants.STRUCTIFICATION_STRUCT_PREFIX); } }
google/guava
1,112
guava-tests/test/com/google/common/collect/Derived.java
/* * Copyright (C) 2007 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 com.google.common.annotations.GwtCompatible; import com.google.common.annotations.GwtIncompatible; import com.google.common.annotations.J2ktIncompatible; import org.jspecify.annotations.NullUnmarked; /** Simple derived class to verify that we handle generics correctly. */ @GwtCompatible @NullUnmarked class Derived extends Base { public Derived(String s) { super(s); } @GwtIncompatible @J2ktIncompatible private static final long serialVersionUID = 0; }
google/j2objc
1,065
jre_emul/android/platform/libcore/luni/src/test/java/libcore/javax/crypto/MockKey.java
/* * Copyright 2013 The Android Open Source Project * * 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 libcore.javax.crypto; import java.security.Key; /** * A mock Key class used for testing. */ @SuppressWarnings("serial") public class MockKey implements Key { @Override public String getAlgorithm() { return "MOCK"; } @Override public String getFormat() { return "MOCK"; } @Override public byte[] getEncoded() { throw new UnsupportedOperationException("not implemented"); } }
google/jsinterop-base
1,113
javatests/jsinterop/base/CheckedModeTest.java
/* * Copyright 2018 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 jsinterop.base; import static jsinterop.base.ExceptionAssert.assertThrowsClassCastException; import org.junit.Test; import org.junit.runner.RunWith; import org.junit.runners.JUnit4; @RunWith(JUnit4.class) public final class CheckedModeTest { @Test public void testThrowClassCastException() throws Exception { assertThrowsClassCastException(() -> Js.asArrayLike(5)); assertThrowsClassCastException(() -> Js.asDouble(new Object())); assertThrowsClassCastException(() -> Js.asInt(15.5d)); } }
google/open-location-code
1,058
android_demo/android/src/main/java/com/openlocationcode/android/direction/DirectionPresenter.java
/* * Copyright 2016 Google Inc. 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 com.openlocationcode.android.direction; public class DirectionPresenter implements DirectionContract.ActionsListener { private final DirectionView mView; public DirectionPresenter(DirectionView view) { mView = view; } @Override public void directionUpdated(Direction direction) { mView.showDirection(direction.getInitialBearing()); mView.showDistance(direction.getDistance()); } }
googleads/google-ads-java
1,050
google-ads-stubs-v19/src/main/java/com/google/ads/googleads/v19/services/GetGoogleAdsFieldRequestOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v19/services/google_ads_field_service.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v19.services; public interface GetGoogleAdsFieldRequestOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v19.services.GetGoogleAdsFieldRequest) com.google.protobuf.MessageOrBuilder { /** * <pre> * Required. The resource name of the field to get. * </pre> * * <code>string resource_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }</code> * @return The resourceName. */ java.lang.String getResourceName(); /** * <pre> * Required. The resource name of the field to get. * </pre> * * <code>string resource_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }</code> * @return The bytes for resourceName. */ com.google.protobuf.ByteString getResourceNameBytes(); }
googleads/google-ads-java
1,050
google-ads-stubs-v20/src/main/java/com/google/ads/googleads/v20/services/GetGoogleAdsFieldRequestOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v20/services/google_ads_field_service.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v20.services; public interface GetGoogleAdsFieldRequestOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v20.services.GetGoogleAdsFieldRequest) com.google.protobuf.MessageOrBuilder { /** * <pre> * Required. The resource name of the field to get. * </pre> * * <code>string resource_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }</code> * @return The resourceName. */ java.lang.String getResourceName(); /** * <pre> * Required. The resource name of the field to get. * </pre> * * <code>string resource_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }</code> * @return The bytes for resourceName. */ com.google.protobuf.ByteString getResourceNameBytes(); }
googleads/google-ads-java
1,050
google-ads-stubs-v21/src/main/java/com/google/ads/googleads/v21/services/GetGoogleAdsFieldRequestOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v21/services/google_ads_field_service.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v21.services; public interface GetGoogleAdsFieldRequestOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v21.services.GetGoogleAdsFieldRequest) com.google.protobuf.MessageOrBuilder { /** * <pre> * Required. The resource name of the field to get. * </pre> * * <code>string resource_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }</code> * @return The resourceName. */ java.lang.String getResourceName(); /** * <pre> * Required. The resource name of the field to get. * </pre> * * <code>string resource_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }</code> * @return The bytes for resourceName. */ com.google.protobuf.ByteString getResourceNameBytes(); }
googleads/google-ads-java
1,052
google-ads-stubs-v20/src/main/java/com/google/ads/googleads/v20/common/WebpageListInfoOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v20/common/criteria.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v20.common; public interface WebpageListInfoOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v20.common.WebpageListInfo) com.google.protobuf.MessageOrBuilder { /** * <pre> * Shared set resource name of the webpage list. * </pre> * * <code>optional string shared_set = 1;</code> * @return Whether the sharedSet field is set. */ boolean hasSharedSet(); /** * <pre> * Shared set resource name of the webpage list. * </pre> * * <code>optional string shared_set = 1;</code> * @return The sharedSet. */ java.lang.String getSharedSet(); /** * <pre> * Shared set resource name of the webpage list. * </pre> * * <code>optional string shared_set = 1;</code> * @return The bytes for sharedSet. */ com.google.protobuf.ByteString getSharedSetBytes(); }
googleads/google-ads-java
1,052
google-ads-stubs-v21/src/main/java/com/google/ads/googleads/v21/common/WebpageListInfoOrBuilder.java
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/ads/googleads/v21/common/criteria.proto // Protobuf Java Version: 3.25.7 package com.google.ads.googleads.v21.common; public interface WebpageListInfoOrBuilder extends // @@protoc_insertion_point(interface_extends:google.ads.googleads.v21.common.WebpageListInfo) com.google.protobuf.MessageOrBuilder { /** * <pre> * Shared set resource name of the webpage list. * </pre> * * <code>optional string shared_set = 1;</code> * @return Whether the sharedSet field is set. */ boolean hasSharedSet(); /** * <pre> * Shared set resource name of the webpage list. * </pre> * * <code>optional string shared_set = 1;</code> * @return The sharedSet. */ java.lang.String getSharedSet(); /** * <pre> * Shared set resource name of the webpage list. * </pre> * * <code>optional string shared_set = 1;</code> * @return The bytes for sharedSet. */ com.google.protobuf.ByteString getSharedSetBytes(); }
googleapis/api-compiler
1,062
src/main/java/com/google/api/tools/framework/importers/swagger/OpenApiConversionException.java
/* * Copyright (C) 2016 Google, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.google.api.tools.framework.importers.swagger; /** Exception indicating failure during conversion of swagger to service config. */ public class OpenApiConversionException extends Exception { public OpenApiConversionException(String message) { super(message); } public OpenApiConversionException(String message, Throwable cause) { super(message, cause); } public OpenApiConversionException(Throwable cause) { super(cause); } }
googlesamples/io2015-codelabs
1,055
search-samples/android-deep-linking/app/src/main/java/com/recipe_app/client/HomeActivity.java
/* * Copyright 2014 Google Inc. 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 com.recipe_app.client; import android.app.Activity; import android.content.Intent; import android.os.Bundle; import com.recipe_app.R; /** * This Activity class defines the home screen for the recipe app. */ public class HomeActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_home); } }
hibernate/hibernate-ogm
1,072
core/src/main/java/org/hibernate/ogm/compensation/ErrorHandlingStrategy.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.compensation; /** * A strategy for dealing with errors occurring during execution of a grid dialect operation. * * @author Gunnar Morling */ public enum ErrorHandlingStrategy { /** * The current unit of work will be aborted, no further grid dialect operations will be executed. The causing * exception will be raised. */ ABORT, /** * The current unit of work will be continued, the remaining grid dialect operations will be executed. The causing * exception will be ignored. * <p> * Care must be taken with this strategy on transactional datastores: If the exception was raised by the datastore * itself, it may be possible that datastore marks the transaction for rollback, not allowing to commit it later on, * also if the exception has been suppressed. */ CONTINUE; }
hibernate/hibernate-orm
1,032
hibernate-core/src/test/java/org/hibernate/orm/test/inheritance/embeddable/SubChildOneEmbeddable.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.orm.test.inheritance.embeddable; import jakarta.persistence.DiscriminatorValue; import jakarta.persistence.Embeddable; /** * @author Marco Belladelli */ //tag::embeddable-inheritance-sub-child-one-example[] @Embeddable @DiscriminatorValue( "sub_child_one" ) class SubChildOneEmbeddable extends ChildOneEmbeddable { private Double subChildOneProp; // ... //end::embeddable-inheritance-sub-child-one-example[] public SubChildOneEmbeddable() { } public SubChildOneEmbeddable(String parentProp, Integer childOneProp, Double subChildOneProp) { super( parentProp, childOneProp ); this.subChildOneProp = subChildOneProp; } public Double getSubChildOneProp() { return subChildOneProp; } public void setSubChildOneProp(Double subChildOneProp) { this.subChildOneProp = subChildOneProp; } //tag::embeddable-inheritance-sub-child-one-example[] } //end::embeddable-inheritance-sub-child-one-example[]
hibernate/hibernate-orm
1,041
hibernate-core/src/main/java/org/hibernate/cfg/C3p0Settings.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.cfg; /** * @author Steve Ebersole */ public interface C3p0Settings { /** * A setting prefix used to indicate settings that target the hibernate-c3p0 integration */ String C3P0_CONFIG_PREFIX = "hibernate.c3p0"; /** * Maximum size of C3P0 connection pool */ String C3P0_MAX_SIZE = "hibernate.c3p0.max_size"; /** * Minimum size of C3P0 connection pool */ String C3P0_MIN_SIZE = "hibernate.c3p0.min_size"; /** * Maximum idle time for C3P0 connection pool */ String C3P0_TIMEOUT = "hibernate.c3p0.timeout"; /** * Maximum size of C3P0 statement cache */ String C3P0_MAX_STATEMENTS = "hibernate.c3p0.max_statements"; /** * Number of connections acquired when pool is exhausted */ String C3P0_ACQUIRE_INCREMENT = "hibernate.c3p0.acquire_increment"; /** * Idle time before a C3P0 pooled connection is validated */ String C3P0_IDLE_TEST_PERIOD = "hibernate.c3p0.idle_test_period"; }
hibernate/hibernate-orm
1,041
hibernate-core/src/test/java/org/hibernate/orm/test/jpa/criteria/idclass/Widget.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.orm.test.jpa.criteria.idclass; import jakarta.persistence.Column; import jakarta.persistence.Entity; import jakarta.persistence.Id; import jakarta.persistence.IdClass; import jakarta.persistence.Table; /** * @author Erich Heard */ @Entity @Table( name = "WIDGET" ) @IdClass( WidgetId.class ) public class Widget { @Id private String code; public String getCode( ) { return this.code; } public void setCode( String value ) { this.code = value; } @Id private String division; public String getDivision( ) { return this.division; } public void setDivision( String value ) { this.division = value; } @Column( name = "COST" ) private Double cost; public Double getCost( ) { return this.cost; } public void setCost( Double value ) { this.cost = value; } @Override public String toString( ) { return "[Code:" + this.getCode( ) + "; Division: " + this.getDivision( ) + "; Cost: " + this.getCost( ) + "]"; } }
hibernate/hibernate-validator
1,028
test-utils/src/main/java/org/hibernate/validator/testutil/CountValidationCallsValidator.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.validator.testutil; import jakarta.validation.ConstraintValidator; import jakarta.validation.ConstraintValidatorContext; /** * @author Kevin Pollet &lt;kevin.pollet@serli.com&gt; (C) 2011 SERLI */ public class CountValidationCallsValidator implements ConstraintValidator<CountValidationCalls, Object> { private static final ThreadLocal<Integer> NUMBER_OF_VALIDATION_CALLS = new ThreadLocal<Integer>() { @Override protected Integer initialValue() { return 0; } }; public static void init() { NUMBER_OF_VALIDATION_CALLS.set( 0 ); } public static int getNumberOfValidationCall() { return NUMBER_OF_VALIDATION_CALLS.get(); } @Override public void initialize(CountValidationCalls constraintAnnotation) { } @Override public boolean isValid(Object value, ConstraintValidatorContext context) { NUMBER_OF_VALIDATION_CALLS.set( NUMBER_OF_VALIDATION_CALLS.get() + 1 ); return true; } }
hibernate/hibernate-validator
1,054
engine/src/test/java/org/hibernate/validator/test/internal/xml/MyConstraint.java
/* * SPDX-License-Identifier: Apache-2.0 * Copyright Red Hat Inc. and Hibernate Authors */ package org.hibernate.validator.test.internal.xml; import static java.lang.annotation.ElementType.FIELD; import static java.lang.annotation.ElementType.METHOD; import static java.lang.annotation.ElementType.TYPE; 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; @Documented @Constraint(validatedBy = MyConstraintValidator.class) @Target({ TYPE, METHOD, FIELD }) @Retention(RUNTIME) public @interface MyConstraint { String message() default "MyConstraint is not valid"; Class<?>[] groups() default { }; Class<? extends Payload>[] payload() default { }; AdditionalConstraint[] additionalConstraints() default { }; public @interface AdditionalConstraint { String message() default "AdditionalConstraint is not valid"; String constraint(); } }
openjdk/jdk8
1,090
langtools/test/tools/javac/diags/examples/DeprecatedPluralAdditional/DeprecatedClass.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. */ @Deprecated class DeprecatedClass { }
openjdk/jdk8
1,099
jdk/test/java/rmi/server/RMIClassLoader/loadProxyClasses/PublicInterface.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. */ /* * */ public interface PublicInterface {}
openjdk/jdk8
1,116
langtools/test/com/sun/javadoc/testLinkToSerialForm/pkg/C.java
/* * Copyright (c) 2002, 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 C implements java.io.Serializable {}
openjdk/jdk8
1,121
jdk/test/sun/rmi/rmic/minimizeWrapperInstances/PImpl.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. */ public class PImpl implements P { public void m(boolean b) { } }
openjdk/jdk8
1,121
langtools/test/com/sun/javadoc/testUnnamedPackage/C.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. */ /** * This is a class in the unnamed package. */ public class C {}
openjdk/jdk8
1,121
langtools/test/tools/javac/ImportCycle/foo/Bottom2.java
/* * Copyright (c) 1997, 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. */ package foo; import foo.Top2.*; public interface Bottom2 { }
openjdk/jdk8
1,130
langtools/test/tools/javac/binaryCompat/T2.java
/* * Copyright (c) 2002, 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. */ class T2 extends T1 { static void f() { } static boolean ok = true; }
openjdk/jdk8
1,133
langtools/test/tools/javac/6902720/E2.java
/* * Copyright (c) 2009, 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. */ enum E2 { A(1), B(2) { }, C(3) { void m() { } }; E2(int i) { } }