repo_id stringclasses 875
values | size int64 974 38.9k | file_path stringlengths 10 308 | content stringlengths 974 38.9k |
|---|---|---|---|
apache/geode | 1,179 | geode-junit/src/main/java/org/apache/geode/test/micrometer/MeterAssert.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.geode.test.micrometer;
import io.micrometer.core.instrument.Meter;
/**
* Assertions for {@code Meter}s.
*/
public class MeterAssert extends AbstractMeterAssert<MeterAssert, Meter> {
/**
* Creates an assertion to evaluate the given meter.
*
* @param meter the meter to evaluate
*/
MeterAssert(Meter meter) {
super(meter, MeterAssert.class);
}
}
|
apache/gobblin | 1,144 | gobblin-modules/gobblin-parquet-common/src/main/java/org/apache/gobblin/parquet/writer/ParquetWriterShim.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.gobblin.parquet.writer;
import java.io.Closeable;
import java.io.IOException;
/**
* An interface to shield gobblin-parquet-common integration from different parquet version specific interfaces
* @param <D>
*/
public interface ParquetWriterShim<D> extends Closeable {
void write(D record)
throws IOException;
}
|
apache/gobblin | 1,150 | gobblin-metastore/src/test/java/org/apache/gobblin/metastore/DatabaseJobHistoryStoreV103Test.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.gobblin.metastore;
import org.testng.annotations.Test;
/**
* Unit tests for {@link DatabaseJobHistoryStore} V1.0.1.
*
*/
@Test(groups = {"gobblin.metastore"})
public class DatabaseJobHistoryStoreV103Test extends DatabaseJobHistoryStoreTest {
@Override
protected String getVersion() {
return "1.0.3";
}
}
|
apache/groovy | 1,167 | subprojects/groovy-xml/src/main/java/groovy/xml/markupsupport/SingleQuoteFilter.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 groovy.xml.markupsupport;
import java.util.Optional;
import java.util.function.Function;
public class SingleQuoteFilter implements Function<Character, Optional<String>> {
@Override
public Optional<String> apply(Character ch) {
if (ch == '\'') return Optional.of("'");
else return Optional.empty();
}
}
|
apache/guacamole-client | 1,109 | extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/security/SaltService.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.guacamole.auth.jdbc.security;
/**
* A service to generate password salts.
*/
public interface SaltService {
/**
* Generates a new String that can be used as a password salt.
* @return a new salt for password encryption.
*/
public byte[] generateSalt();
}
|
apache/hadoop-common | 1,094 | hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/TestLocalMRNotification.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.hadoop.mapred;
import java.io.IOException;
/**
* Tests Job end notification in local mode.
*/
public class TestLocalMRNotification extends NotificationTestCase {
public TestLocalMRNotification() throws IOException {
super(HadoopTestCase.LOCAL_MR);
}
}
|
apache/hadoop-common | 1,128 | hadoop-tools/hadoop-openstack/src/main/java/org/apache/hadoop/fs/swift/exceptions/SwiftUnsupportedFeatureException.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.hadoop.fs.swift.exceptions;
/**
* Exception raised on an unsupported feature in the FS API -such as
* <code>append()</code>
*/
public class SwiftUnsupportedFeatureException extends SwiftException {
public SwiftUnsupportedFeatureException(String message) {
super(message);
}
}
|
apache/hadoop | 1,143 | hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/common/blockaliasmap/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.
*/
/**
* The AliasMap defines mapping of PROVIDED HDFS blocks to data in remote
* storage systems.
*/
@InterfaceAudience.Public
@InterfaceStability.Unstable
package org.apache.hadoop.hdfs.server.common.blockaliasmap;
import org.apache.hadoop.classification.InterfaceAudience;
import org.apache.hadoop.classification.InterfaceStability; |
apache/hadoop | 1,145 | hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/event/Event.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.hadoop.yarn.event;
import org.apache.hadoop.classification.InterfaceAudience.Public;
import org.apache.hadoop.classification.InterfaceStability.Evolving;
/**
* Interface defining events api.
*
*/
@Public
@Evolving
public interface Event<TYPE extends Enum<TYPE>> {
TYPE getType();
long getTimestamp();
String toString();
}
|
apache/hadoop | 1,149 | hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/ProtobufRpcEngineCallback.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.hadoop.ipc;
import com.google.protobuf.Message;
/**
* This engine uses Protobuf 2.5.0. Recommended to upgrade to Protobuf 3.x
* from hadoop-thirdparty and use ProtobufRpcEngineCallback2.
*/
@Deprecated
public interface ProtobufRpcEngineCallback {
void setResponse(Message message);
void error(Throwable t);
} |
apache/hadoop | 1,152 | hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/statistics/S3AStatisticInterface.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.hadoop.fs.s3a.statistics;
import org.apache.hadoop.fs.statistics.DurationTrackerFactory;
import org.apache.hadoop.fs.statistics.IOStatisticsSource;
/**
* Base Interface for S3A Statistics, as a way of managing
* them.
*/
public interface S3AStatisticInterface extends IOStatisticsSource,
DurationTrackerFactory {
}
|
apache/harmony | 1,162 | classlib/modules/awt/src/main/java/common/org/apache/harmony/awt/state/ListState.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.
*/
/**
* @author Dmitry A. Durnev
*/
package org.apache.harmony.awt.state;
import java.awt.Rectangle;
/**
* ListState
*/
public interface ListState extends State {
Rectangle getItemBounds(int idx);
Rectangle getClient();
int getItemCount();
boolean isSelected(int idx);
String getItem(int idx);
int getCurrentIndex();
}
|
apache/harmony | 1,164 | classlib/modules/swing/src/main/java/common/javax/swing/text/BadLocationException.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.
*/
/**
* @author Alexey A. Ivanov
*/
package javax.swing.text;
public class BadLocationException extends Exception {
private int offset;
public BadLocationException(final String description, final int offset) {
super(description);
this.offset = offset;
}
public int offsetRequested() {
return offset;
}
}
|
apache/helix | 1,169 | helix-core/src/test/java/org/apache/helix/integration/manager/ZkTestManager.java | package org.apache.helix.integration.manager;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT 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.List;
import org.apache.helix.manager.zk.CallbackHandler;
import org.apache.helix.zookeeper.api.client.RealmAwareZkClient;
public interface ZkTestManager {
RealmAwareZkClient getZkClient();
List<CallbackHandler> getHandlers();
String getInstanceName();
String getClusterName();
}
|
apache/helix | 1,181 | helix-core/src/main/java/org/apache/helix/ExternalViewChangeListener.java | package org.apache.helix;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
/**
* Interface to implement to be notified of changes to the external view.
*
* @deprecated
* NOTE: This interface definition is moved to {@link org.apache.helix.api.listeners.ExternalViewChangeListener}
*/
@Deprecated
public interface ExternalViewChangeListener extends
org.apache.helix.api.listeners.ExternalViewChangeListener {
}
|
apache/hive | 1,175 | jdbc/src/java/org/apache/hive/jdbc/ZooKeeperHiveClientException.java | /*
* 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. See accompanying LICENSE file.
*/
package org.apache.hive.jdbc;
public class ZooKeeperHiveClientException extends Exception {
private static final long serialVersionUID = 0;
/**
* @param cause (original exception)
*/
public ZooKeeperHiveClientException(Throwable cause) {
super(cause);
}
/**
* @param msg (exception message)
*/
public ZooKeeperHiveClientException(String msg) {
super(msg);
}
/**
* @param msg (exception message)
* @param cause (original exception)
*/
public ZooKeeperHiveClientException(String msg, Throwable cause) {
super(msg, cause);
}
}
|
apache/hive | 1,177 | ql/src/java/org/apache/hadoop/hive/ql/lockmgr/HiveLockManagerCtx.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.hadoop.hive.ql.lockmgr;
import org.apache.hadoop.hive.conf.HiveConf;
public class HiveLockManagerCtx {
HiveConf conf;
public HiveLockManagerCtx() {
}
public HiveLockManagerCtx(HiveConf conf) {
this.conf = conf;
}
public HiveConf getConf() {
return conf;
}
public void setConf(HiveConf conf) {
this.conf = conf;
}
}
|
apache/ignite-3 | 1,130 | modules/cluster-management/src/test/java/org/apache/ignite/internal/cluster/management/raft/TestClusterStateStorageTest.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.ignite.internal.cluster.management.raft;
/**
* Test class for {@link TestClusterStateStorage}.
*/
public class TestClusterStateStorageTest extends AbstractClusterStateStorageTest {
@Override
ClusterStateStorage createStorage(String nodeName) {
return new TestClusterStateStorage();
}
}
|
apache/ignite-3 | 1,151 | modules/cli/src/main/java/org/apache/ignite/internal/cli/core/repl/terminal/TerminalCustomizer.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.ignite.internal.cli.core.repl.terminal;
import org.jline.terminal.Terminal;
/**
* Interface for customize provided instance of {@link Terminal}.
*/
public interface TerminalCustomizer {
/**
* Customize method.
*
* @param terminal provided terminal instance.
*/
void customize(Terminal terminal);
}
|
apache/ignite-3 | 1,156 | modules/client-common/src/main/java/org/apache/ignite/internal/client/proto/tx/ClientTxUtils.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.ignite.internal.client.proto.tx;
/**
* Utility class for client transactions.
*/
public class ClientTxUtils {
/** Tx resource id for directly mapped request. */
public static final long TX_ID_DIRECT = 0L;
/** Tx resource id for directly mapped first request. */
public static final long TX_ID_FIRST_DIRECT = -1L;
}
|
apache/ignite-3 | 1,163 | modules/eventlog/src/test/java/org/apache/ignite/internal/eventlog/ser/Message.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.ignite.internal.eventlog.ser;
class Message {
private final int version;
private final String body;
public Message(int version, String body) {
this.version = version;
this.body = body;
}
public int getVersion() {
return version;
}
public String getBody() {
return body;
}
}
|
apache/incubator-brooklyn | 1,127 | brooklyn-library/software/webapp/src/main/java/org/apache/brooklyn/entity/proxy/AbstractNonProvisionedController.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.brooklyn.entity.proxy;
import org.apache.brooklyn.api.entity.Entity;
import org.apache.brooklyn.api.entity.ImplementedBy;
@ImplementedBy(AbstractNonProvisionedControllerImpl.class)
public interface AbstractNonProvisionedController extends LoadBalancer, Entity {
public boolean isActive();
}
|
apache/incubator-brooklyn | 1,135 | brooklyn-library/software/webapp/src/main/java/org/apache/brooklyn/entity/webapp/tomcat/Tomcat7SshDriver.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.brooklyn.entity.webapp.tomcat;
import org.apache.brooklyn.location.ssh.SshMachineLocation;
@Deprecated
public class Tomcat7SshDriver extends TomcatSshDriver implements Tomcat7Driver {
public Tomcat7SshDriver(TomcatServerImpl entity, SshMachineLocation machine) {
super(entity, machine);
}
} |
apache/incubator-brooklyn | 1,137 | brooklyn-library/software/nosql/src/main/java/org/apache/brooklyn/entity/nosql/solr/SolrServerDriver.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.brooklyn.entity.nosql.solr;
import org.apache.brooklyn.entity.java.JavaSoftwareProcessDriver;
import org.apache.brooklyn.entity.software.base.SoftwareProcessDriver;
public interface SolrServerDriver extends JavaSoftwareProcessDriver {
Integer getSolrPort();
String getSolrConfigTemplateUrl();
}
|
apache/incubator-hivemall | 1,181 | core/src/test/java/hivemall/utils/hadoop/Text2Test.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 hivemall.utils.hadoop;
import org.junit.Assert;
import org.junit.Test;
public class Text2Test {
@Test
public void test() {
byte[] expected = "this is a test".getBytes();
Text2 text = new Text2(expected);
Assert.assertArrayEquals(expected, text.getBytes());
Assert.assertEquals(expected.length, text.getLength());
}
}
|
apache/incubator-kie-drools | 1,127 | drools-test-coverage/test-compiler-integration/src/test/java/org/drools/mvel/compiler/SpecialString.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.drools.mvel.compiler;
public class SpecialString {
private String text;
public SpecialString(String text) {
this.text = text;
}
public String getText() {
return text;
}
public String toString() {
return (getText() + "[" + super.toString() + "]");
}
}
|
apache/incubator-kie-kogito-runtimes | 1,095 | kogito-serverless-workflow/kogito-serverless-workflow-grpc-runtime/src/main/java/org/kie/kogito/serverless/workflow/rpc/RPCConverter.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.kie.kogito.serverless.workflow.rpc;
import com.fasterxml.jackson.databind.JsonNode;
import com.google.protobuf.Message;
public interface RPCConverter {
Message.Builder buildMessage(Object object, Message.Builder builder);
JsonNode getJsonNode(Message message);
}
|
apache/incubator-kie-kogito-runtimes | 1,152 | jbpm/jbpm-flow/src/main/java/org/jbpm/workflow/core/node/RuleUnitFactory.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.jbpm.workflow.core.node;
import org.drools.ruleunits.api.RuleUnit;
import org.drools.ruleunits.api.RuleUnitData;
import org.kie.api.runtime.process.ProcessContext;
public interface RuleUnitFactory<T extends RuleUnitData> {
T bind(ProcessContext ctx);
RuleUnit<T> unit();
void unbind(ProcessContext ctx, T model);
}
|
apache/incubator-kie-optaplanner | 1,140 | optaplanner-benchmark/src/main/java/org/optaplanner/benchmark/config/blueprint/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.
*/
@XmlSchema(
namespace = PlannerBenchmarkConfig.XML_NAMESPACE,
elementFormDefault = XmlNsForm.QUALIFIED)
package org.optaplanner.benchmark.config.blueprint;
import jakarta.xml.bind.annotation.XmlNsForm;
import jakarta.xml.bind.annotation.XmlSchema;
import org.optaplanner.benchmark.config.PlannerBenchmarkConfig;
|
apache/incubator-kie-optaplanner | 1,140 | optaplanner-benchmark/src/main/java/org/optaplanner/benchmark/config/statistic/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.
*/
@XmlSchema(
namespace = PlannerBenchmarkConfig.XML_NAMESPACE,
elementFormDefault = XmlNsForm.QUALIFIED)
package org.optaplanner.benchmark.config.statistic;
import jakarta.xml.bind.annotation.XmlNsForm;
import jakarta.xml.bind.annotation.XmlSchema;
import org.optaplanner.benchmark.config.PlannerBenchmarkConfig;
|
apache/incubator-myriad | 1,143 | myriad-scheduler/src/main/java/org/apache/myriad/scheduler/event/FrameworkMessageEventFactory.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
* <p/>
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.myriad.scheduler.event;
import com.lmax.disruptor.EventFactory;
/**
* framework message event factory
*/
public class FrameworkMessageEventFactory implements EventFactory<FrameworkMessageEvent> {
@Override
public FrameworkMessageEvent newInstance() {
return new FrameworkMessageEvent();
}
}
|
apache/incubator-retired-wave | 1,145 | wave/src/main/java/org/waveprotocol/wave/client/editor/content/HasDisplayEditModes.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.waveprotocol.wave.client.editor.content;
/**
* ContentElements that needs to know about display vs. edit mode should
* implement this interface
*
*/
public interface HasDisplayEditModes {
/**
* Will be called when editor changes mode
*
* @param editing
*/
void onEditorModeChange(boolean editing);
}
|
apache/incubator-retired-wave | 1,151 | wave/src/main/java/org/waveprotocol/box/server/persistence/lucene/IndexDirectory.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.waveprotocol.box.server.persistence.lucene;
import org.apache.lucene.store.Directory;
import org.waveprotocol.box.server.waveserver.IndexException;
/**
* Provides the directory to store/access the index files.
*
* @author A. Kaplanov
*/
public interface IndexDirectory {
Directory getDirectory() throws IndexException;
}
|
apache/incubator-tez | 1,145 | tez-runtime-internals/src/main/java/org/apache/tez/runtime/api/events/TaskAttemptFailedEvent.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.tez.runtime.api.events;
import org.apache.tez.runtime.api.Event;
public class TaskAttemptFailedEvent extends Event {
private final String diagnostics;
public TaskAttemptFailedEvent(String diagnostics) {
this.diagnostics = diagnostics;
}
public String getDiagnostics() {
return diagnostics;
}
}
|
apache/incubator-tuweni | 1,179 | rlpx/src/main/java/org/apache/tuweni/rlpx/wire/PongMessage.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.tuweni.rlpx.wire;
import org.apache.tuweni.bytes.Bytes;
final class PongMessage implements WireProtocolMessage {
static PongMessage read(Bytes data) {
return new PongMessage();
}
@Override
public Bytes toBytes() {
throw new UnsupportedOperationException();
}
@Override
public int messageType() {
throw new UnsupportedOperationException();
}
}
|
apache/incubator-wayang | 1,158 | wayang-ml4all/src/main/java/org/apache/wayang/ml4all/abstraction/api/Transform.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.wayang.ml4all.abstraction.api;
import java.io.Serializable;
public abstract class Transform<R, V> extends LogicalOperator {
/**
* Parses and transforms an input data unit
*
* @param input usually a line of a file
* @return the transformed data point
*/
public abstract R transform (V input);
}
|
apache/inlong | 1,144 | inlong-sort/sort-common/src/test/java/org/apache/inlong/sort/protocol/node/format/DebeziumJsonFormatTest.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.protocol.node.format;
import org.apache.inlong.sort.SerializeBaseTest;
/**
* Test for {@link DebeziumJsonFormat}
*/
public class DebeziumJsonFormatTest extends SerializeBaseTest<DebeziumJsonFormat> {
@Override
public DebeziumJsonFormat getTestObject() {
return new DebeziumJsonFormat();
}
}
|
apache/iotdb | 1,115 | iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/pipe/sink/payload/pipeconsensus/request/PipeConsensusRequestVersion.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.pipe.sink.payload.pipeconsensus.request;
public enum PipeConsensusRequestVersion {
VERSION_1((byte) 1),
;
private final byte version;
PipeConsensusRequestVersion(byte type) {
this.version = type;
}
public byte getVersion() {
return version;
}
}
|
apache/iotdb | 1,150 | iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/flush/CloseFileListener.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.storageengine.dataregion.flush;
import org.apache.iotdb.db.exception.TsFileProcessorException;
import org.apache.iotdb.db.storageengine.dataregion.memtable.TsFileProcessor;
@FunctionalInterface
public interface CloseFileListener {
void onClosed(TsFileProcessor processor) throws TsFileProcessorException;
}
|
apache/jackrabbit-oak | 1,144 | oak-jackrabbit-api/src/main/java/org/apache/jackrabbit/api/security/principal/JackrabbitPrincipal.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.api.security.principal;
import java.security.Principal;
import org.osgi.annotation.versioning.ProviderType;
/**
* <code>JackrabbitPrincipal</code> marks the principal to be the result of
* authentication against the repository.
*/
@ProviderType
public interface JackrabbitPrincipal extends Principal {
}
|
apache/jackrabbit-oak | 1,163 | oak-blob/src/test/java/org/apache/jackrabbit/oak/spi/blob/MemoryBlobStoreTest.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.spi.blob;
/**
* Tests the MemoryBlobStore implementation.
*/
public class MemoryBlobStoreTest extends AbstractBlobStoreTest {
@Override
public void setUp() throws Exception {
store = new MemoryBlobStore();
store.setBlockSize(128);
((MemoryBlobStore) store).setBlockSizeMin(48);
}
}
|
apache/jackrabbit | 1,169 | jackrabbit-webdav/src/test/java/org/apache/jackrabbit/webdav/lock/TestAll.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.webdav.lock;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
public class TestAll extends TestCase {
public static Test suite() {
TestSuite suite = new TestSuite("WebDAV lock tests");
suite.addTestSuite(ActiveLockTest.class);
return suite;
}
} |
apache/jclouds | 1,143 | providers/azureblob/src/test/java/org/jclouds/azureblob/blobstore/integration/AzureBlobContainerLiveTest.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.jclouds.azureblob.blobstore.integration;
import org.jclouds.blobstore.integration.internal.BaseContainerLiveTest;
import org.testng.annotations.Test;
@Test(groups = { "live" })
public class AzureBlobContainerLiveTest extends BaseContainerLiveTest {
public AzureBlobContainerLiveTest() {
provider = "azureblob";
}
}
|
apache/jclouds | 1,151 | apis/atmos/src/test/java/org/jclouds/atmos/blobstore/integration/AtmosServiceIntegrationLiveTest.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.jclouds.atmos.blobstore.integration;
import org.jclouds.blobstore.integration.internal.BaseServiceIntegrationTest;
import org.testng.annotations.Test;
@Test(groups = "live")
public class AtmosServiceIntegrationLiveTest extends BaseServiceIntegrationTest {
public AtmosServiceIntegrationLiveTest() {
provider = "atmos";
}
}
|
apache/jclouds | 1,179 | apis/docker/src/main/java/org/jclouds/docker/domain/StatusCode.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.jclouds.docker.domain;
import org.jclouds.json.SerializedNames;
import com.google.auto.value.AutoValue;
@AutoValue
public abstract class StatusCode {
public abstract int statusCode();
StatusCode() {
}
@SerializedNames({ "StatusCode" })
public static StatusCode create(int statusCode) {
return new AutoValue_StatusCode(statusCode);
}
}
|
apache/jena | 1,171 | jena-db/jena-dboe-base/src/main/java/org/apache/jena/dboe/base/file/AlreadyLocked.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.dboe.base.file;
import org.apache.jena.dboe.DBOpEnvException;
/** Exception throws when an attempt to take a {@link ProcessFileLock}
* with a call of {@link ProcessFileLock#lockEx}
* is made and the lock is already held.
*/
public class AlreadyLocked extends DBOpEnvException {
public AlreadyLocked(String msg) { super(msg); }
}
|
apache/jena | 1,181 | jena-core/src/main/java/org/apache/jena/rdf/model/HasNoModelException.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.rdf.model;
import org.apache.jena.shared.JenaException ;
/**
Exception to throw when a Statement or Resource (which don't have
a useful common supertype, alas) don't have an associated model.
*/
public class HasNoModelException extends JenaException
{
public HasNoModelException( Object x )
{ super( x.toString() ); }
}
|
apache/jena | 1,193 | jena-arq/src/main/java/org/apache/jena/rdfs/SetupRDFS.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.rdfs;
import org.apache.jena.graph.Graph;
import org.apache.jena.graph.Node;
import org.apache.jena.rdfs.setup.BaseSetupRDFS;
/** RDFS setup in Node space */
public class SetupRDFS extends BaseSetupRDFS<Node> {
public SetupRDFS(Graph vocab) {
super(vocab);
}
@Override
protected Node fromNode(Node node) {
return node;
}
}
|
apache/kafka | 1,151 | connect/runtime/src/main/java/org/apache/kafka/connect/runtime/distributed/RebalanceNeededException.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.connect.runtime.distributed;
import org.apache.kafka.connect.errors.ConnectException;
/**
* Indicates that a request cannot be completed because a rebalance is expected to begin.
*/
public class RebalanceNeededException extends ConnectException {
public RebalanceNeededException(String s) {
super(s);
}
}
|
apache/kafka | 1,167 | clients/src/main/java/org/apache/kafka/common/errors/InvalidPrincipalTypeException.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.common.errors;
public class InvalidPrincipalTypeException extends ApiException {
private static final long serialVersionUID = 1L;
public InvalidPrincipalTypeException(String message) {
super(message);
}
public InvalidPrincipalTypeException(String message, Throwable cause) {
super(message, cause);
}
}
|
apache/kafka | 1,168 | clients/src/main/java/org/apache/kafka/common/errors/InvalidSessionTimeoutException.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.common.errors;
public class InvalidSessionTimeoutException extends ApiException {
private static final long serialVersionUID = 1L;
public InvalidSessionTimeoutException(String message, Throwable cause) {
super(message, cause);
}
public InvalidSessionTimeoutException(String message) {
super(message);
}
}
|
apache/kafka | 1,172 | server-common/src/test/java/org/apache/kafka/server/common/MetadataVersionTestUtils.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.server.common;
public class MetadataVersionTestUtils {
// References to feature levels that are no longer supported in production, but still useful in tests
public static final short IBP_3_0_IV1_FEATURE_LEVEL = 1;
public static final short IBP_3_3_IV0_FEATURE_LEVEL = 4;
public static final short IBP_3_3_IV2_FEATURE_LEVEL = 6;
}
|
apache/kylin | 1,154 | src/common-service/src/main/java/org/apache/kylin/rest/response/ExecutorMemoryResponse.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.kylin.rest.response;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Getter;
import lombok.Setter;
@Getter
@Setter
public class ExecutorMemoryResponse {
@JsonProperty("name")
private String executorName;
@JsonProperty("mem_infos")
private List<String> memInfos;
}
|
apache/lens | 1,174 | lens-server/src/main/java/org/apache/lens/server/ServiceProviderFactoryImpl.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.lens.server;
import org.apache.lens.server.api.ServiceProvider;
import org.apache.lens.server.api.ServiceProviderFactory;
/**
* The Class ServiceProviderFactoryImpl.
*/
public class ServiceProviderFactoryImpl implements ServiceProviderFactory {
@Override
public ServiceProvider getServiceProvider() {
return LensServices.get();
}
}
|
apache/lens | 1,179 | lens-cube/src/main/java/org/apache/lens/cube/parse/CheckTableNames.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.lens.cube.parse;
import org.apache.lens.server.api.error.LensException;
import org.apache.hadoop.conf.Configuration;
public class CheckTableNames extends ValidationRule {
public CheckTableNames(Configuration conf) {
super(conf);
}
@Override
public boolean validate(CubeQueryContext ctx) throws LensException {
return true;
}
}
|
apache/logging-log4j2 | 1,166 | log4j-1.2-api/src/main/java/org/apache/log4j/spi/DefaultRepositorySelector.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.log4j.spi;
public class DefaultRepositorySelector implements RepositorySelector {
final LoggerRepository repository;
public DefaultRepositorySelector(final LoggerRepository repository) {
this.repository = repository;
}
@Override
public LoggerRepository getLoggerRepository() {
return repository;
}
}
|
apache/metamodel | 1,173 | core/src/main/java/org/apache/metamodel/query/parser/WhereItemParser.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.metamodel.query.parser;
import org.apache.metamodel.query.Query;
final class WhereItemParser implements QueryPartProcessor {
private final Query _query;
public WhereItemParser(Query query) {
_query = query;
}
@Override
public void parse(String delim, String itemToken) {
_query.where(itemToken);
}
}
|
apache/metamodel | 1,183 | core/src/main/java/org/apache/metamodel/schema/WrappingTable.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.metamodel.schema;
/**
* Sub-interface for {@link Table}s that wrap other {@link Table}s, typically to apply some client-side enhancement
* logic.
*/
public interface WrappingTable extends Table {
/**
* Gets the {@link Table} that is wrapped by this {@link WrappingTable}.
*
* @return
*/
public Table getWrappedTable();
}
|
apache/metron | 1,109 | metron-platform/metron-enrichment/metron-enrichment-common/src/main/java/org/apache/metron/enrichment/lookup/accesstracker/AccessTrackerCreator.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.metron.enrichment.lookup.accesstracker;
import org.apache.metron.hbase.TableProvider;
import java.io.IOException;
import java.util.Map;
public interface AccessTrackerCreator {
public AccessTracker create(Map<String, Object> config, TableProvider provider) throws IOException;
}
|
apache/metron | 1,116 | metron-platform/metron-indexing/metron-indexing-common/src/main/java/org/apache/metron/indexing/dao/metaalert/MetaAlertStatus.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.metron.indexing.dao.metaalert;
public enum MetaAlertStatus {
ACTIVE("active"),
INACTIVE("inactive");
private String statusString;
MetaAlertStatus(String statusString) {
this.statusString = statusString;
}
public String getStatusString() {
return statusString;
}
}
|
apache/nifi | 1,130 | nifi-commons/nifi-jetty-configuration/src/main/java/org/apache/nifi/jetty/configuration/connector/ServerConnectorFactory.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.jetty.configuration.connector;
import org.eclipse.jetty.server.ServerConnector;
/**
* Jetty Server Connector Factory
*/
public interface ServerConnectorFactory {
/**
* Get Server Connector
*
* @return Configured Server Connector
*/
ServerConnector getServerConnector();
}
|
apache/openjpa | 1,131 | openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/common/apps/TransactionalClassPC.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.datacache.common.apps;
import jakarta.persistence.Entity;
@Entity
public class TransactionalClassPC {
private int intField;
public int getIntField() {
return this.intField;
}
public void setIntField(int intField) {
this.intField = intField;
}
}
|
apache/openjpa | 1,172 | openjpa-kernel/src/main/java/org/apache/openjpa/event/PersistListener.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.event;
/**
* Listener for newly-persisted instances.
*
* @author Steve Kim
*/
public interface PersistListener {
/**
* Invoked before an instance is persisted.
*/
void beforePersist(LifecycleEvent event);
/**
* Invoked when an instance is persisted.
*/
void afterPersist(LifecycleEvent event);
}
|
apache/openwebbeans | 1,123 | webbeans-impl/src/test/java/org/apache/webbeans/test/concepts/alternatives/common/DefaultBeanProducerWithoutDisposes.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.concepts.alternatives.common;
import jakarta.enterprise.inject.Produces;
public class DefaultBeanProducerWithoutDisposes
{
public @Produces @QualifierProducerBased
IProducedBean generateBean()
{
return new ProducedBean("defaultwithoutdisposes", this);
}
}
|
apache/openwebbeans | 1,154 | webbeans-impl/src/test/java/org/apache/webbeans/test/decorators/broken/BrokenName.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.decorators.broken;
import jakarta.decorator.Decorator;
import jakarta.decorator.Delegate;
import jakarta.inject.Inject;
import jakarta.inject.Named;
@Decorator
@Named
public class BrokenName implements IBroken
{
private @Inject @Delegate IBroken borken;
@Override
public void broke()
{
}
}
|
apache/phoenix-omid | 1,163 | benchmarks/src/main/java/org/apache/omid/benchmarks/utils/UniformGenerator.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.omid.benchmarks.utils;
import java.util.Random;
public class UniformGenerator extends IntegerGenerator {
private final Random ramdom = new Random(System.nanoTime());
@Override
public int nextInt() {
return ramdom.nextInt(Integer.MAX_VALUE);
}
@Override
public double mean() {
return 0;
}
}
|
apache/poi | 1,182 | poi-ooxml/src/main/java/org/apache/poi/xssf/binary/XSSFBParseException.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.xssf.binary;
/**
* Parse exception while reading an xssfb.
*
* @since 3.16-beta3
*/
public class XSSFBParseException extends RuntimeException {
public XSSFBParseException(String msg) {
super(msg);
}
}
|
apache/polygene-java | 1,149 | libraries/rest-common/src/main/java/org/apache/polygene/library/rest/common/table/Column.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.library.rest.common.table;
import org.apache.polygene.api.property.Property;
import org.apache.polygene.api.value.ValueComposite;
/**
* JAVADOC
*/
public interface Column
extends ValueComposite
{
Property<String> id();
Property<String> label();
Property<String> columnType();
}
|
apache/pulsar | 1,142 | pulsar-client-admin-api/src/main/java/org/apache/pulsar/common/policies/data/PersistentTopicInternalStats.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;
import java.util.List;
/**
* Persistent topic internal statistics.
*/
public class PersistentTopicInternalStats extends ManagedLedgerInternalStats{
public List<LedgerInfo> schemaLedgers;
// LedgerInfo for compacted topic if exist.
public LedgerInfo compactedLedger;
}
|
apache/pulsar | 1,169 | pulsar-client/src/main/java/org/apache/pulsar/client/impl/TopicMetadataImpl.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.client.impl;
import org.apache.pulsar.client.api.TopicMetadata;
class TopicMetadataImpl implements TopicMetadata {
private final int numPartitions;
TopicMetadataImpl(int numPartitions) {
this.numPartitions = numPartitions;
}
@Override
public int numPartitions() {
return numPartitions;
}
}
|
apache/pulsar | 1,171 | pulsar-broker/src/main/java/org/apache/pulsar/broker/loadbalance/LoadCalculator.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.broker.loadbalance;
/**
* This interface class defines how we calculator the
* resource requirement per service unit based on the ServiceRequest.
*/
public interface LoadCalculator {
ResourceDescription getResourceDescription(ServiceRequest srvRequest);
void recalibrateResourceUsagePerServiceUnit(LoadReport loadReport);
}
|
apache/pulsar | 1,172 | pulsar-metadata/src/main/java/org/apache/pulsar/metadata/api/GetResult.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.metadata.api;
import lombok.Data;
/**
* Represent a result for a {@link MetadataStore#get(String)} operation.
*/
@Data
public class GetResult {
/**
* The value of the key stored.
*/
private final byte[] value;
/**
* The {@link Stat} object associated with the value.
*/
private final Stat stat;
}
|
apache/ratis | 1,176 | ratis-test/src/test/java/org/apache/ratis/netty/TestGroupManagementWithNetty.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.ratis.netty;
import org.apache.ratis.server.impl.MiniRaftCluster;
import org.apache.ratis.server.impl.GroupManagementBaseTest;
public class TestGroupManagementWithNetty extends GroupManagementBaseTest {
@Override
public MiniRaftCluster.Factory<? extends MiniRaftCluster> getClusterFactory() {
return MiniRaftClusterWithNetty.FACTORY;
}
}
|
apache/ratis | 1,183 | ratis-common/src/main/java/org/apache/ratis/protocol/GroupInfoRequest.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.ratis.protocol;
/**
* Client sends this request to a server to request for the information about
* the server itself.
*/
public class GroupInfoRequest extends RaftClientRequest {
public GroupInfoRequest(ClientId clientId, RaftPeerId serverId, RaftGroupId groupId, long callId) {
super(clientId, serverId, groupId, callId, readRequestType());
}
}
|
apache/ratis | 1,183 | ratis-common/src/main/java/org/apache/ratis/protocol/GroupListRequest.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.ratis.protocol;
/**
* Client sends this request to a server to request for the information about
* the server itself.
*/
public class GroupListRequest extends RaftClientRequest {
public GroupListRequest(ClientId clientId, RaftPeerId serverId, RaftGroupId groupId, long callId) {
super(clientId, serverId, groupId, callId, readRequestType());
}
}
|
apache/reef | 1,138 | lang/java/reef-bridge-proto-java/src/main/java/org/apache/reef/bridge/client/grpc/parameters/ClientServerPort.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.bridge.client.grpc.parameters;
import org.apache.reef.tang.annotations.Name;
import org.apache.reef.tang.annotations.NamedParameter;
/**
* Client server port.
*/
@NamedParameter(doc = "the gRPC client server port", default_value = "0")
public final class ClientServerPort implements Name<Integer> {
}
|
apache/reef | 1,157 | lang/java/reef-wake/wake/src/main/java/org/apache/reef/wake/time/runtime/event/RuntimeAlarm.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.wake.time.runtime.event;
import org.apache.reef.wake.EventHandler;
import org.apache.reef.wake.time.event.Alarm;
/**
* An event for non-client alarm.
*/
public final class RuntimeAlarm extends Alarm {
public RuntimeAlarm(final long timestamp, final EventHandler<Alarm> handler) {
super(timestamp, handler);
}
}
|
apache/rocketmq-connect | 1,143 | connectors/rocketmq-replicator/src/main/java/org/apache/rocketmq/replicator/common/LoggerName.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.replicator.common;
/**
* Define all the logger name of the runtime.
*/
public class LoggerName {
public static final String CONNECT_BUG = "ConnectBug";
public static final String REPLICATRO_RUNTIME = "ReplicatorRuntime";
public static final String WORKER_ERROR_MSG_ID = "WorkerErrorMsgId";
}
|
apache/servicecomb-java-chassis | 1,114 | clients/service-center-client/src/main/java/org/apache/servicecomb/service/center/client/model/ModifySchemasRequest.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.service.center.client.model;
import java.util.List;
public class ModifySchemasRequest {
private List<SchemaInfo> schemas;
public List<SchemaInfo> getSchemas() {
return schemas;
}
public void setSchemas(List<SchemaInfo> schemas) {
this.schemas = schemas;
}
}
|
apache/servicecomb-java-chassis | 1,120 | demo/demo-springmvc/springmvc-server/src/main/java/org/apache/servicecomb/demo/springmvc/server/MyStrategy.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.demo.springmvc.server;
import org.apache.servicecomb.qps.strategy.AbstractQpsStrategy;
public class MyStrategy extends AbstractQpsStrategy {
@Override
public boolean isLimitNewRequest() {
return false;
}
@Override
public String name() {
return "MyStrategy";
}
}
|
apache/servicecomb-java-chassis | 1,124 | foundations/foundation-common/src/main/java/org/apache/servicecomb/foundation/common/utils/bean/MapSetter.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.foundation.common.utils.bean;
import java.util.Map;
public class MapSetter<K, V> implements Setter<Map<K, V>, V> {
private final K key;
public MapSetter(K key) {
this.key = key;
}
@Override
public void set(Map<K, V> instance, V value) {
instance.put(key, value);
}
}
|
apache/servicecomb-java-chassis | 1,134 | common/common-rest/src/main/java/org/apache/servicecomb/common/rest/codec/query/QueryCodecSsv.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.common.rest.codec.query;
/**
* ?query=x1%20x2
*/
public class QueryCodecSsv extends QueryCodecWithDelimiter {
public static final String CODEC_NAME = "spaceDelimited:0";
public static final String DELIMITER = " ";
public QueryCodecSsv() {
super(CODEC_NAME, DELIMITER, DELIMITER);
}
}
|
apache/servicecomb-saga-actuator | 1,155 | saga-core/src/test/java/org/apache/servicecomb/saga/core/CompensationImpl.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.saga.core;
import java.util.Map;
public class CompensationImpl extends RestOperation implements Compensation {
public CompensationImpl(String path, String method, Map<String, Map<String, String>> params) {
super(path, method, params);
}
@Override
public int retries() {
return DEFAULT_RETRIES;
}
}
|
apache/servicecomb-samples | 1,117 | java-chassis-integration-tests/demo-schema/src/main/java/org/apache/servicecomb/demo/server/DefaultAbstractModel.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.demo.server;
public class DefaultAbstractModel extends AbstractModel {
@Override
public String getType() {
return "default";
}
@Override
public String getName() {
return this.name;
}
@Override
public void setName(String name) {
this.name = name;
}
}
|
apache/shardingsphere | 1,108 | parser/distsql/statement/src/main/java/org/apache/shardingsphere/distsql/statement/type/rdl/rule/database/DatabaseRuleDefinitionStatement.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.rdl.rule.database;
import org.apache.shardingsphere.distsql.statement.type.rdl.rule.RuleDefinitionStatement;
/**
* Database rule definition statement.
*/
public abstract class DatabaseRuleDefinitionStatement extends RuleDefinitionStatement {
}
|
apache/shardingsphere | 1,130 | infra/rewrite/core/src/main/java/org/apache/shardingsphere/infra/rewrite/engine/result/GenericSQLRewriteResult.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.infra.rewrite.engine.result;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
/**
* Generic SQL rewrite result.
*/
@RequiredArgsConstructor
@Getter
public final class GenericSQLRewriteResult implements SQLRewriteResult {
private final SQLRewriteUnit sqlRewriteUnit;
}
|
apache/shenyu | 1,159 | shenyu-admin/src/main/java/org/apache/shenyu/admin/model/page/condition/SwitchCondition.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.shenyu.admin.model.page.condition;
/**
* search condition. used boolean status condition.
*/
public interface SwitchCondition {
/**
* get switch status.<br>
* <p>the true is open,enable,yes... </p>
* <p>the false is close,unable,no... </p>
*
* @return status
*/
Boolean getSwitchStatus();
}
|
apache/shenyu | 1,161 | shenyu-disruptor/src/main/java/org/apache/shenyu/disruptor/event/DisruptorEventFactory.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.shenyu.disruptor.event;
import com.lmax.disruptor.EventFactory;
/**
* DisruptorEventFactory.
* disruptor Create a factory implementation of the object.
*/
public class DisruptorEventFactory<T> implements EventFactory<DataEvent<T>> {
@Override
public DataEvent<T> newInstance() {
return new DataEvent<>();
}
}
|
apache/sis | 1,150 | endorsed/src/org.apache.sis.metadata/main/org/apache/sis/pending/geoapi/temporal/IndeterminateValue.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.sis.pending.geoapi.temporal;
import java.util.Locale;
/**
* Indications that a temporal position is not precisely known.
*
* @author Martin Desruisseaux (Geomatys)
*/
public enum IndeterminateValue {
UNKNOWN, NOW, BEFORE, AFTER;
public String identifier() {
return name().toLowerCase(Locale.US);
}
}
|
apache/sis | 1,157 | endorsed/src/org.apache.sis.storage.geotiff/main/org/apache/sis/storage/geotiff/base/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.
*/
/**
* Shared classes for the implementation of GeoTIFF reader and writer.
*
* <STRONG>Do not use!</STRONG>
*
* This package is for internal use by SIS only. Classes in this package
* may change in incompatible ways in any future version without notice.
*
* @author Martin Desruisseaux (Geomatys)
*/
package org.apache.sis.storage.geotiff.base;
|
apache/solr | 1,174 | solr/solrj-streaming/src/java/org/apache/solr/client/solrj/io/ops/StreamOperation.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.solr.client.solrj.io.ops;
import java.io.Serializable;
import org.apache.solr.client.solrj.io.Tuple;
import org.apache.solr.client.solrj.io.stream.expr.Expressible;
/** Interface for any operation one can perform on a tuple in a TupleStream */
public interface StreamOperation extends Expressible, Serializable {
public void operate(Tuple tuple);
}
|
apache/sqoop | 1,189 | src/test/org/apache/sqoop/testutil/adapter/DatabaseAdapter.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.sqoop.testutil.adapter;
import org.apache.sqoop.SqoopOptions;
import org.apache.sqoop.manager.ConnManager;
import java.sql.SQLException;
public interface DatabaseAdapter {
String getConnectionString();
SqoopOptions injectConnectionParameters(SqoopOptions options);
void dropTableIfExists(String tableName, ConnManager manager) throws SQLException;
}
|
apache/sqoop | 1,193 | src/java/org/apache/sqoop/util/ErrorableThread.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.sqoop.util;
/**
* A thread which has an error bit which can be set from within the thread.
*/
public abstract class ErrorableThread extends Thread {
private volatile boolean error;
public ErrorableThread() {
this.error = false;
}
protected void setError() {
this.error = true;
}
public boolean isErrored() {
return this.error;
}
}
|
apache/storm | 1,168 | flux/flux-core/src/main/java/org/apache/storm/flux/model/BeanListReference.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.flux.model;
import java.util.List;
/**
* A bean list reference is a list of bean reference.
*/
public class BeanListReference {
public List<String> ids;
public BeanListReference() {}
public BeanListReference(List<String> ids) {
this.ids = ids;
}
public List<String> getIds() {
return ids;
}
}
|
apache/stormcrawler | 1,181 | core/src/main/java/org/apache/stormcrawler/proxy/ProxyManager.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.stormcrawler.proxy;
import java.util.Optional;
import org.apache.storm.Config;
import org.apache.stormcrawler.Metadata;
/**
* Proxy manager is an abstract class specification that details the required interface of a proxy
* manager
*/
public interface ProxyManager {
void configure(Config conf);
Optional<SCProxy> getProxy(Metadata metadata);
}
|
apache/stratos | 1,104 | components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/listener/application/ApplicationInstanceInactivatedEventListener.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.stratos.messaging.listener.application;
import org.apache.stratos.messaging.listener.EventListener;
/**
* This listener will get triggered upon the application inactivated event.
*/
public abstract class ApplicationInstanceInactivatedEventListener extends EventListener {
}
|
apache/stratos | 1,104 | components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/listener/application/ApplicationInstanceTerminatingEventListener.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.stratos.messaging.listener.application;
import org.apache.stratos.messaging.listener.EventListener;
/**
* This listener will get triggered upon the application terminating event.
*/
public abstract class ApplicationInstanceTerminatingEventListener extends EventListener {
}
|
apache/streampark | 1,123 | streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/base/exception/InternalException.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.streampark.console.base.exception;
/** System Internal Exception */
public class InternalException extends Exception {
public InternalException(String message) {
super(message);
}
public InternalException(String message, Throwable cause) {
super(message, cause);
}
}
|
apache/struts | 1,129 | plugins/convention/src/test/java/org/apache/struts2/convention/actions/parentpackage/sub/ClassLevelParentPackageChildAction.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.convention.actions.parentpackage.sub;
import org.apache.struts2.convention.actions.parentpackage.ClassLevelParentPackageAction;
/**
* Extends an action that hass a @ParentPackage at the class level
*/
public class ClassLevelParentPackageChildAction extends ClassLevelParentPackageAction {
}
|
apache/struts | 1,131 | plugins/convention/src/test/java/org/apache/struts2/convention/actions/parentpackage/ClassLevelParentPackageAction.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.convention.actions.parentpackage;
import org.apache.struts2.convention.annotation.ParentPackage;
/**
* <p>
* This is a parent package usage action.
* </p>
*/
@ParentPackage("class-level")
public class ClassLevelParentPackageAction {
public String execute() {
return null;
}
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.