repo_id stringclasses 875
values | size int64 974 38.9k | file_path stringlengths 10 308 | content stringlengths 974 38.9k |
|---|---|---|---|
hibernate/hibernate-orm | 1,074 | hibernate-core/src/test/java/org/hibernate/orm/test/annotations/manytomany/CatPk.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.orm.test.annotations.manytomany;
import java.io.Serializable;
import jakarta.persistence.Column;
/**
* @author Emmanuel Bernard
*/
public class CatPk implements Serializable {
private String name;
private String thoroughbred;
@Column(length=128)
public String getThoroughbred() {
return thoroughbred;
}
public void setThoroughbred(String thoroughbred) {
this.thoroughbred = thoroughbred;
}
@Column(length=128)
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public boolean equals(Object o) {
if ( this == o ) return true;
if ( !( o instanceof CatPk ) ) return false;
final CatPk catPk = (CatPk) o;
if ( !name.equals( catPk.name ) ) return false;
if ( !thoroughbred.equals( catPk.thoroughbred ) ) return false;
return true;
}
public int hashCode() {
int result;
result = name.hashCode();
result = 29 * result + thoroughbred.hashCode();
return result;
}
}
|
hibernate/hibernate-orm | 1,098 | hibernate-core/src/main/java/org/hibernate/event/spi/AutoFlushEvent.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.event.spi;
import java.util.Set;
/**
* Event class for {@link org.hibernate.FlushMode#AUTO automatic}
* stateful session flush.
*
* @author Steve Ebersole
*/
public class AutoFlushEvent extends FlushEvent {
private Set<String> querySpaces;
private boolean flushRequired;
private final boolean skipPreFlush;
public AutoFlushEvent(Set<String> querySpaces, EventSource source) {
this( querySpaces, false, source );
}
public AutoFlushEvent(Set<String> querySpaces, boolean skipPreFlush, EventSource source) {
super( source );
this.querySpaces = querySpaces;
this.skipPreFlush = skipPreFlush;
}
public Set<String> getQuerySpaces() {
return querySpaces;
}
public void setQuerySpaces(Set<String> querySpaces) {
this.querySpaces = querySpaces;
}
public boolean isFlushRequired() {
return flushRequired;
}
public void setFlushRequired(boolean dirty) {
this.flushRequired = dirty;
}
public boolean isSkipPreFlush() {
return skipPreFlush;
}
}
|
hibernate/hibernate-orm | 1,113 | hibernate-core/src/test/java/org/hibernate/orm/test/bulkid/GlobalTemporaryTableMutationStrategyIdTest.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.orm.test.bulkid;
import org.hibernate.query.sqm.mutation.internal.temptable.GlobalTemporaryTableInsertStrategy;
import org.hibernate.query.sqm.mutation.internal.temptable.GlobalTemporaryTableMutationStrategy;
import org.hibernate.query.sqm.mutation.spi.SqmMultiTableInsertStrategy;
import org.hibernate.query.sqm.mutation.spi.SqmMultiTableMutationStrategy;
import org.hibernate.testing.orm.junit.DialectFeatureChecks;
import org.hibernate.testing.orm.junit.RequiresDialectFeature;
@RequiresDialectFeature(feature = DialectFeatureChecks.SupportsGlobalTemporaryTable.class)
public class GlobalTemporaryTableMutationStrategyIdTest extends AbstractMutationStrategyIdTest {
@Override
protected Class<? extends SqmMultiTableMutationStrategy> getMultiTableMutationStrategyClass() {
return GlobalTemporaryTableMutationStrategy.class;
}
@Override
protected Class<? extends SqmMultiTableInsertStrategy> getMultiTableInsertStrategyClass() {
return GlobalTemporaryTableInsertStrategy.class;
}
}
|
hibernate/hibernate-search | 1,088 | backend/lucene/src/main/java/org/hibernate/search/backend/lucene/document/model/impl/LuceneIndexValueFieldTemplate.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.search.backend.lucene.document.model.impl;
import org.hibernate.search.backend.lucene.types.impl.LuceneIndexValueFieldType;
import org.hibernate.search.engine.common.tree.spi.TreeNodeInclusion;
import org.hibernate.search.util.common.pattern.spi.SimpleGlobPattern;
public class LuceneIndexValueFieldTemplate
extends AbstractLuceneIndexFieldTemplate<LuceneIndexValueFieldType<?>> {
public LuceneIndexValueFieldTemplate(LuceneIndexCompositeNode declaringParent,
SimpleGlobPattern absolutePathGlob, LuceneIndexValueFieldType<?> type, TreeNodeInclusion inclusion,
boolean multiValued) {
super( declaringParent, absolutePathGlob, type, inclusion, multiValued );
}
@Override
protected LuceneIndexField createNode(LuceneIndexCompositeNode parent, String relativePath,
LuceneIndexValueFieldType<?> type, TreeNodeInclusion inclusion, boolean multiValued) {
return new LuceneIndexValueField<>( parent, relativePath, type, inclusion, multiValued, true );
}
}
|
hibernate/hibernate-search | 1,131 | engine/src/main/java/org/hibernate/search/engine/environment/bean/spi/BeanConfigurer.java | /*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.search.engine.environment.bean.spi;
/**
* An object responsible for defining beans that can then be resolved during Hibernate Search bootstrap.
* <p>
* Bean configurers can be enabled through two different methods:
* <ul>
* <li>Java services: create a file named {@code org.hibernate.search.engine.environment.bean.spi.BeanConfigurer}
* in the {@code META-INF/services} directory of your JAR,
* and set the content of this file to the fully-qualified name of your {@link BeanConfigurer} implementation.
* <li>Configuration properties: set the {@link org.hibernate.search.engine.cfg.spi.EngineSpiSettings#BEAN_CONFIGURERS}
* configuration property (be sure to use the appropriate prefix for the property key, e.g. {@code hibernate.search.}).
* </ul>
*/
public interface BeanConfigurer {
/**
* Configure beans as necessary using the given {@code context}.
* @param context A context exposing methods to configure beans.
*/
void configure(BeanConfigurationContext context);
}
|
openjdk/jdk8 | 1,158 | langtools/test/tools/javadoc/annotations/annotateMethodsFields/pkg1/A.java | /*
* Copyright (c) 2003, 2004, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package pkg1;
public @interface A {
interface N {
}
@A("value")
String value();
}
|
openjdk/jdk8 | 1,159 | langtools/test/tools/javac/diags/examples/NoteProcMessager/NoteProcMessager.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// key: compiler.note.proc.messager
// options: -processor AnnoProc -proc:only
class NoteProcMessager { }
|
openjdk/jdk8 | 1,159 | langtools/test/tools/javac/diags/examples/WarnProcMessager/WarnProcMessager.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// key: compiler.warn.proc.messager
// options: -processor AnnoProc -proc:only
class WarnProcMessager { }
|
openjdk/jdk8 | 1,171 | langtools/test/tools/javac/diags/examples/FinallyWithoutTry.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// key: compiler.err.finally.without.try
class FinallyWithoutTry {
void m() {
finally {
}
}
}
|
openjdk/jdk8 | 1,172 | langtools/test/com/sun/javadoc/testDocRootInlineTag/pkg/C.java | /*
* Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package pkg;
/**
* My package page is <a href="{@docRoot}/pkg/package-summary.html">here</a>
*
*/
public class C {}
|
openjdk/jdk8 | 1,173 | langtools/test/tools/javac/generics/rawSeparate/CharScanner.java | /*
* Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package antlr;
import util.Hashtable;
public class CharScanner {
protected Hashtable literals; // set by subclass
}
|
openjdk/jdk8 | 1,174 | langtools/test/tools/javac/diags/examples/InvalidHexNumber.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// key: compiler.err.invalid.hex.number
// key: compiler.err.expected
class InvalidHexNumber {
int i = 0xz1357abc;
}
|
openjdk/jdk8 | 1,177 | langtools/test/tools/javac/diags/examples/RawClassUse.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// key: compiler.warn.raw.class.use
// options: -Xlint:rawtypes
import java.util.*;
class RawClassUse {
ArrayList l;
}
|
openjdk/jdk8 | 1,178 | langtools/test/tools/javac/diags/examples/ClassCantWrite.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// key: compiler.err.class.cant.write
// run: jsr199 -filemanager cantWrite:.*/ClassCantWrite.class
class ClassCantWrite { }
|
openjdk/jdk8 | 1,183 | langtools/test/tools/javah/6572945/TestClass2.java | /*
* Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
public class TestClass2 {
byte b;
short s;
int i;
long l;
float f;
double d;
Object o;
String t;
}
|
openjdk/jdk8 | 1,186 | langtools/test/tools/javac/T6956462/TestClass.java | /*
* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
import java.io.PrintStream;
abstract class TestClass {
private void test() {
final PrintStream out = System.out;
}
}
|
openjdk/jtreg | 1,176 | test/modlibs/buildAction/usermods/um1/um1_p1/um1_p1_B.java | /*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package um1_p1;
public class um1_p1_B {
public void run() {
System.out.println(getClass().getName());
}
}
|
openjdk/jtreg | 1,176 | test/modlibs/buildAction/usermods/um2/um2_p1/um2_p1_B.java | /*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package um2_p1;
public class um2_p1_B {
public void run() {
System.out.println(getClass().getName());
}
}
|
openjdk/jtreg | 1,197 | test/reportOption/to-be-run/Pass.java | /*
* Copyright (c) 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
// tests in this directory are to be run
/*
* @test
* @run main Pass
*/
public class Pass {
public static void main(String... args) { }
} |
openjdk/jtreg | 1,200 | test/share/basic/main/CantFindSrc.java | /*
* Copyright (c) 1999, 2007, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/* @test
* @summary Error: Can't find source file: CannotFindSrc.java in directory-list: .../data/basic/main
* @run main CannotFindSrc
*/
|
oracle/coherence | 1,096 | prj/coherence-grpc/src/main/java/com/oracle/coherence/grpc/internal/extend/message/response/CollectionOfInt32Response.java | /*
* Copyright (c) 2000, 2025, Oracle and/or its affiliates.
*
* Licensed under the Universal Permissive License v 1.0 as shown at
* https://oss.oracle.com/licenses/upl.
*/
package com.oracle.coherence.grpc.internal.extend.message.response;
import com.google.protobuf.Message;
import com.oracle.coherence.grpc.MessageHelper;
import com.tangosol.coherence.component.net.extend.message.response.GrpcResponse;
import com.tangosol.io.Serializer;
/**
* A {@link GrpcResponse} that produces a
* {@link com.oracle.coherence.grpc.messages.common.v1.CollectionOfInt32}.
*
* @author Jonathan Knight 2024.11.26
*/
public class CollectionOfInt32Response
extends BaseProxyResponse
{
public CollectionOfInt32Response()
{
}
@Override
@SuppressWarnings("unchecked")
public Message getMessage()
{
Object o = getResult();
if (o instanceof int[])
{
return MessageHelper.toCollectionOfInt32((int[]) o);
}
return MessageHelper.toCollectionOfInt32((Iterable<Integer>) o);
}
}
|
oracle/coherence | 1,107 | prj/test/functional/jcache/src/main/java/com/tangosol/coherence/jcachetesting/PofJcacheTestContext.java | /*
* Copyright (c) 2000, 2022, Oracle and/or its affiliates.
*
* Licensed under the Universal Permissive License v 1.0 as shown at
* https://oss.oracle.com/licenses/upl.
*/
package com.tangosol.coherence.jcachetesting;
import java.net.URI;
/**
* Test Context for POF support.
* This context test user type pof and Coherence Jcache Adapter's pof methods for EntryProcessors and serializers for
* jcache specification of Duration and ExpiryPolicy class implementations.
*
* @version 1.0
* @author jfialli
*/
public class PofJcacheTestContext
extends AbstractJcacheTestContext
{
/**
* {@inheritDoc}
*/
@Override
public URI getDistributedCacheConfigURI()
{
return getURI("junit-client-distributed-cache-config.xml");
}
/**
* {@inheritDoc}
*/
@Override
public URI getServerCacheConfigURI()
{
return getURI("junit-server-cache-config.xml");
}
/**
* {@inheritDoc}
*/
@Override
public boolean supportsPof()
{
return true;
}
}
|
oracle/coherence | 1,119 | prj/coherence-core/src/main/java/com/tangosol/coherence/config/xml/processor/SubscriberGroupProcessor.java | /*
* Copyright (c) 2000, 2020, Oracle and/or its affiliates.
*
* Licensed under the Universal Permissive License v 1.0 as shown at
* http://oss.oracle.com/licenses/upl.
*/
package com.tangosol.coherence.config.xml.processor;
import com.tangosol.coherence.config.builder.SubscriberGroupBuilder;
import com.tangosol.config.ConfigurationException;
import com.tangosol.config.xml.ElementProcessor;
import com.tangosol.config.xml.ProcessingContext;
import com.tangosol.config.xml.XmlSimpleName;
import com.tangosol.run.xml.XmlElement;
/**
* A {@link ElementProcessor} for the <subscriber-group> element.
*
* @author jf 2016.03.02
* @since Coherence 14.1.1
*/
@XmlSimpleName("subscriber-group")
public class SubscriberGroupProcessor implements ElementProcessor<SubscriberGroupBuilder>
{
@Override
public SubscriberGroupBuilder process(ProcessingContext context, XmlElement xmlElement)
throws ConfigurationException
{
SubscriberGroupBuilder builder = new SubscriberGroupBuilder();
context.inject(builder, xmlElement);
return builder;
}
}
|
oracle/coherence | 1,140 | prj/coherence-core/src/main/java/com/tangosol/dev/compiler/SyntaxException.java | /*
* Copyright (c) 2000, 2020, Oracle and/or its affiliates.
*
* Licensed under the Universal Permissive License v 1.0 as shown at
* http://oss.oracle.com/licenses/upl.
*/
package com.tangosol.dev.compiler;
/**
* The SyntaxException exception is equivalent to the "syntax error" message
* that a user sees when a script cannot compile. It allows a parser to throw
* the exception from the depths of its syntactic analysis and catch it (if
* desired) and recover at a much higher level.
*
* @version 1.00, 09/14/98
* @author Cameron Purdy
*/
public class SyntaxException
extends CompilerException
{
/**
* Constructs a SyntaxException with no detail message.
* A detail message is a String that describes this particular exception.
*/
public SyntaxException()
{
super();
}
/**
* Constructs a SyntaxException with the specified detail message.
* A detail message is a String that describes this particular exception.
* @param s the String that contains a detailed message
*/
public SyntaxException(String s)
{
super(s);
}
}
|
apache/commons-math | 1,123 | commons-math-legacy/src/test/java/org/apache/commons/math4/legacy/util/FrenchComplexFormatTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.commons.math4.legacy.util;
import java.util.Locale;
public class FrenchComplexFormatTest extends ComplexFormatAbstractTest {
@Override
protected char getDecimalCharacter() {
return ',';
}
@Override
protected Locale getLocale() {
return Locale.FRENCH;
}
}
|
apache/cxf | 1,136 | services/xkms/xkms-common/src/main/java/org/apache/cxf/xkms/exception/XKMSLocateException.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.cxf.xkms.exception;
public class XKMSLocateException extends XKMSException {
private static final long serialVersionUID = 868729742068991784L;
public XKMSLocateException(String msg) {
super(msg);
}
public XKMSLocateException(String msg, Throwable e) {
super(msg, e);
}
}
|
apache/cxf | 1,140 | rt/databinding/aegis/src/test/java/org/apache/cxf/aegis/type/java5/dto/MapDTOService.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.cxf.aegis.type.java5.dto;
import java.util.HashMap;
import java.util.Map;
public class MapDTOService {
public MapDTO getDTO() {
MapDTO dto = new MapDTO();
Map<String, Integer> strings = new HashMap<>();
strings.put("hi", 4);
dto.setStrings(strings);
return dto;
}
}
|
apache/directory-fortress-core | 1,140 | src/main/java/org/apache/directory/fortress/core/impl/PropertyProvider.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*
*/
package org.apache.directory.fortress.core.impl;
import org.apache.directory.fortress.core.FinderException;
import org.apache.directory.fortress.core.model.FortEntity;
interface PropertyProvider<T>
{
String getDn( T entity );
FortEntity getEntity( T entity ) throws FinderException;
}
|
apache/dolphinscheduler | 1,115 | dolphinscheduler-common/src/main/java/org/apache/dolphinscheduler/common/constants/SystemConstants.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.dolphinscheduler.common.constants;
import java.util.TimeZone;
import lombok.extern.slf4j.Slf4j;
@Slf4j
public class SystemConstants {
public static final TimeZone DEFAULT_TIME_ZONE = TimeZone.getDefault();
static {
log.info("init timezone: {}", DEFAULT_TIME_ZONE);
}
}
|
apache/doris-spark-connector | 1,126 | spark-load/spark-load-core/src/main/java/org/apache/doris/common/CommandLineOptions.java | // Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The ASF licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may not use this file except in compliance
// with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing,
// software distributed under the License is distributed on an
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
// KIND, either express or implied. See the License for the
// specific language governing permissions and limitations
// under the License.
package org.apache.doris.common;
import lombok.Getter;
@Getter
public class CommandLineOptions {
private final String configPath;
private final Boolean recovery;
public CommandLineOptions(String configPath, Boolean recovery) {
this.configPath = configPath;
this.recovery = recovery;
}
}
|
apache/druid | 1,138 | processing/src/test/java/org/apache/druid/frame/processor/FrameRowTooLargeExceptionTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.druid.frame.processor;
import org.junit.Assert;
import org.junit.Test;
public class FrameRowTooLargeExceptionTest
{
@Test
public void test_getMaxFrameSize()
{
final long maxFrameSize = 100;
Assert.assertEquals(maxFrameSize, new FrameRowTooLargeException(maxFrameSize).getMaxFrameSize());
}
}
|
apache/dubbo-go-hessian2 | 1,159 | test_hessian/src/main/java/test/generic/Response.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package test.generic;
import java.io.Serializable;
public class Response<T> implements Serializable {
private int code;
private T data;
public int getCode() {
return code;
}
public T getData() {
return data;
}
public Response(int code, T data) {
this.code = code;
this.data = data;
}
}
|
apache/dubbo-samples | 1,073 | 2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/expansion/filter/FilterServiceImpl.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.dubbo.rest.demo.expansion.filter;
import org.apache.dubbo.config.annotation.DubboService;
@DubboService
public class FilterServiceImpl implements FilterService {
@Override
public String filterGet(String name) {
return name;
}
}
|
apache/eagle | 1,125 | eagle-security/eagle-security-common/src/main/java/org/apache/eagle/security/hdfs/MAPRFSAuditLogObject.java | /*
*
* * Licensed to the Apache Software Foundation (ASF) under one or more
* * contributor license agreements. See the NOTICE file distributed with
* * this work for additional information regarding copyright ownership.
* * The ASF licenses this file to You under the Apache License, Version 2.0
* * (the "License"); you may not use this file except in compliance with
* * the License. You may obtain a copy of the License at
* *
* * http://www.apache.org/licenses/LICENSE-2.0
* *
* * Unless required by applicable law or agreed to in writing, software
* * distributed under the License is distributed on an "AS IS" BASIS,
* * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* * See the License for the specific language governing permissions and
* * limitations under the License.
*
*/
package org.apache.eagle.security.hdfs;
public class MAPRFSAuditLogObject {
public long timestamp;
public String host;
public String status;
public String user;
public String cmd;
public String src;
public String dst;
public String volume;
}
|
apache/felix-dev | 1,077 | ipojo/runtime/core-it/ipojo-core-bad-configuration-test/src/main/java/org/apache/felix/ipojo/runtime/bad/services/FooService.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.felix.ipojo.runtime.bad.services;
import java.util.Properties;
public interface FooService {
boolean foo();
Properties fooProps();
Boolean getObject();
boolean getBoolean();
int getInt();
long getLong();
double getDouble();
}
|
apache/felix-dev | 1,160 | inventory/src/main/java/org/apache/felix/inventory/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 {@code org.apache.felix.inventory} package exposes the API for
* the Apache Felix Inventory Printer Framework.
*
* @see <a href="http://felix.apache.org/documentation/subprojects/apache-felix-inventory.html">Apache Felix Inventory</a>
* @version 1.0
*/
@org.osgi.annotation.versioning.Version("1.0")
package org.apache.felix.inventory; |
apache/fineract | 1,123 | fineract-e2e-tests-core/src/test/java/org/apache/fineract/test/data/InterestCalculationPeriodTime.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.fineract.test.data;
public enum InterestCalculationPeriodTime {
DAILY(0), //
SAME_AS_REPAYMENT_PERIOD(1); //
public final Integer value;
InterestCalculationPeriodTime(Integer value) {
this.value = value;
}
public Integer getValue() {
return value;
}
}
|
apache/fineract | 1,138 | fineract-core/src/main/java/org/apache/fineract/infrastructure/core/filters/BatchFilter.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.fineract.infrastructure.core.filters;
import jakarta.ws.rs.core.UriInfo;
import org.apache.fineract.batch.domain.BatchRequest;
import org.apache.fineract.batch.domain.BatchResponse;
public interface BatchFilter {
BatchResponse doFilter(BatchRequest batchRequest, UriInfo uriInfo, BatchFilterChain chain);
}
|
apache/flink-connector-aws | 1,086 | flink-connector-aws/flink-connector-dynamodb/src/test/java/org/apache/flink/connector/dynamodb/source/split/StartingPositionTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.connector.dynamodb.source.split;
import nl.jqno.equalsverifier.EqualsVerifier;
import org.junit.jupiter.api.Test;
class StartingPositionTest {
@Test
void testEquals() {
EqualsVerifier.forClass(StartingPosition.class).verify();
}
}
|
apache/flink | 1,132 | flink-kubernetes/src/main/java/org/apache/flink/kubernetes/kubeclient/resources/KubernetesService.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.kubernetes.kubeclient.resources;
import io.fabric8.kubernetes.api.model.Service;
/** Represent Service resource in kubernetes. */
public class KubernetesService extends KubernetesResource<Service> {
public KubernetesService(Service internalResource) {
super(internalResource);
}
}
|
apache/flink | 1,132 | flink-table/flink-table-common/src/main/java/org/apache/flink/table/functions/FunctionRequirement.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.flink.table.functions;
import org.apache.flink.annotation.PublicEvolving;
/** Characteristics that a {@link FunctionDefinition} requires. */
@PublicEvolving
public enum FunctionRequirement {
/** Requirement that an aggregate function can only be applied in an OVER window. */
OVER_WINDOW_ONLY
}
|
apache/fory | 1,167 | java/fory-core/src/main/java/org/apache/fory/annotation/Ignore.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.fory.annotation;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/** Ignore properties just like transient. */
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD, ElementType.METHOD})
public @interface Ignore {}
|
apache/geaflow | 1,106 | geaflow-console/app/core/model/src/main/java/org/apache/geaflow/console/core/model/task/schedule/GeaflowApprovalInfo.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.geaflow.console.core.model.task.schedule;
import lombok.Getter;
import lombok.Setter;
import org.apache.geaflow.console.core.model.GeaflowId;
@Getter
@Setter
public class GeaflowApprovalInfo extends GeaflowId {
private String approvalId;
private boolean success;
}
|
apache/geaflow | 1,111 | geaflow-console/app/common/util/src/main/java/org/apache/geaflow/console/common/util/exception/GeaflowLogException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.geaflow.console.common.util.exception;
import lombok.extern.slf4j.Slf4j;
@Slf4j
public class GeaflowLogException extends GeaflowException {
public GeaflowLogException(String fmt, Object... args) {
super(fmt, args);
log.error(getMessage(), getCause());
}
}
|
apache/geode | 1,133 | geode-log4j/src/integrationTest/java/org/apache/geode/logging/log4j/internal/impl/NonBlankStrings.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more contributor license
* agreements. See the NOTICE file distributed with this work for additional information regarding
* copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the License. You may obtain a
* copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 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.logging.log4j.internal.impl;
import java.util.List;
import java.util.stream.Collectors;
import org.apache.commons.lang3.StringUtils;
class NonBlankStrings {
static List<String> nonBlankStrings(List<String> values) {
return values.stream().filter(StringUtils::isNotBlank).collect(Collectors.toList());
}
}
|
apache/geode | 1,133 | geode-lucene/geode-lucene-test/src/main/java/org/apache/geode/cache/lucene/DummyLuceneSerializer.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more contributor license
* agreements. See the NOTICE file distributed with this work for additional information regarding
* copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the License. You may obtain a
* copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 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.cache.lucene;
import java.util.Collection;
import java.util.Collections;
import org.apache.lucene.document.Document;
public class DummyLuceneSerializer implements LuceneSerializer {
@Override
public Collection<Document> toDocuments(LuceneIndex index, Object value) {
return Collections.emptyList();
}
}
|
apache/gobblin | 1,128 | gobblin-modules/gobblin-kafka-common/src/test/java/org/apache/gobblin/kafka/writer/TestTypeMapper.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.kafka.writer;
import org.apache.gobblin.types.FieldMappingException;
import org.apache.gobblin.types.TypeMapper;
public class TestTypeMapper implements TypeMapper {
@Override
public Object getField(Object record, String fieldPath)
throws FieldMappingException {
return null;
}
}
|
apache/gobblin | 1,149 | gobblin-api/src/main/java/org/apache/gobblin/typedconfig/compiletime/IntRange.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.typedconfig.compiletime;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Target({ElementType.FIELD, ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
public @interface IntRange {
int[] value();
}
|
apache/gobblin | 1,150 | gobblin-runtime/src/main/java/org/apache/gobblin/runtime/CountBasedLimiter.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.runtime;
/**
* {@inheritDoc}
*
* @deprecated This class has been moved to {@link org.apache.gobblin.util.limiter.CountBasedLimiter}.
*/
@Deprecated
public class CountBasedLimiter extends org.apache.gobblin.util.limiter.CountBasedLimiter {
public CountBasedLimiter(long countLimit) {
super(countLimit);
}
}
|
apache/hadoop-common | 1,068 | hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeManagerEvent.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.server.nodemanager;
import org.apache.hadoop.yarn.event.AbstractEvent;
public class NodeManagerEvent extends
AbstractEvent<NodeManagerEventType>{
public NodeManagerEvent(NodeManagerEventType type) {
super(type);
}
}
|
apache/hadoop | 1,127 | hadoop-tools/hadoop-compat-bench/src/main/java/org/apache/hadoop/fs/compat/common/HdfsCompatCaseCleanup.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.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.hadoop.fs.compat.common;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.METHOD})
public @interface HdfsCompatCaseCleanup {
} |
apache/hadoop | 1,127 | hadoop-tools/hadoop-compat-bench/src/main/java/org/apache/hadoop/fs/compat/common/HdfsCompatCasePrepare.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.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.hadoop.fs.compat.common;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.METHOD})
public @interface HdfsCompatCasePrepare {
} |
apache/harmony | 1,114 | classlib/modules/swing/src/test/api/java.injected/javax/swing/text/html/StyleSheet_ConvertAttr_LetterSpacingTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT 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.html;
public class StyleSheet_ConvertAttr_LetterSpacingTest extends
StyleSheet_ConvertAttr_SpacingTestCase {
protected void setUp() throws Exception {
super.setUp();
cssKey = CSS.Attribute.LETTER_SPACING;
}
}
|
apache/harmony | 1,133 | classlib/modules/auth/src/main/java/common/javax/security/auth/login/AccountLockedException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package javax.security.auth.login;
public class AccountLockedException extends AccountException {
private static final long serialVersionUID = 8280345554014066334L;
public AccountLockedException() {
super();
}
public AccountLockedException(String message) {
super(message);
}
}
|
apache/hbase | 1,145 | hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/LeaseRecovery.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.hbase.procedure2.store;
import java.io.IOException;
import org.apache.hadoop.fs.FileSystem;
import org.apache.hadoop.fs.Path;
import org.apache.yetus.audience.InterfaceAudience;
@InterfaceAudience.Private
public interface LeaseRecovery {
void recoverFileLease(FileSystem fs, Path path) throws IOException;
}
|
apache/helix | 1,145 | helix-core/src/main/java/org/apache/helix/manager/zk/client/DedicatedZkClientFactory.java | package org.apache.helix.manager.zk.client;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
/**
* Deprecated; please use DedicatedZkClientFactory in zookeeper-api instead.
*
* Singleton factory that build dedicated clients using the raw ZkClient.
*/
@Deprecated
public class DedicatedZkClientFactory extends org.apache.helix.zookeeper.impl.factory.DedicatedZkClientFactory {
}
|
apache/hertzbeat | 1,138 | hertzbeat-grafana/src/main/java/org/apache/hertzbeat/grafana/dto/GrafanaConfig.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.hertzbeat.grafana.dto;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* System Configuration
*/
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class GrafanaConfig {
/**
* api token
*/
private String token;
}
|
apache/hive | 1,164 | service/src/java/org/apache/hive/service/ServiceException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.hive.service;
/**
* ServiceException.
*
*/
public class ServiceException extends RuntimeException {
public ServiceException(Throwable cause) {
super(cause);
}
public ServiceException(String message) {
super(message);
}
public ServiceException(String message, Throwable cause) {
super(message, cause);
}
}
|
apache/hop | 1,080 | plugins/transforms/cratedbbulkloader/src/main/java/org/apache/hop/pipeline/transforms/cratedbbulkloader/http/exceptions/UnauthorizedCrateDBAccessException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.hop.pipeline.transforms.cratedbbulkloader.http.exceptions;
public class UnauthorizedCrateDBAccessException extends CrateDBHopException {
public UnauthorizedCrateDBAccessException(String body) {
super("Unauthorized CrateDB access", 401, body);
}
}
|
apache/hop | 1,159 | rcp/src/main/java/org/apache/hop/ui/hopgui/context/GuiContextUtilImpl.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.hop.ui.hopgui.context;
import org.apache.hop.ui.hopgui.ISingletonProvider;
public class GuiContextUtilImpl implements ISingletonProvider {
private static GuiContextUtil instance;
@Override
public Object getInstanceInternal() {
if (instance == null) {
instance = new GuiContextUtil();
}
return instance;
}
}
|
apache/hudi | 1,123 | hudi-client/hudi-client-common/src/test/java/org/apache/hudi/testutils/providers/HoodieWriteClientProvider.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.hudi.testutils.providers;
import org.apache.hudi.client.BaseHoodieWriteClient;
import org.apache.hudi.config.HoodieWriteConfig;
import java.io.IOException;
public interface HoodieWriteClientProvider {
BaseHoodieWriteClient getHoodieWriteClient(HoodieWriteConfig cfg) throws IOException;
}
|
apache/iceberg | 1,159 | api/src/main/java/org/apache/iceberg/view/SQLViewRepresentation.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.iceberg.view;
/** SQLViewRepresentation represents views in SQL with a given dialect */
public interface SQLViewRepresentation extends ViewRepresentation {
@Override
default String type() {
return Type.SQL;
}
/** The view query SQL text. */
String sql();
/** The view query SQL dialect. */
String dialect();
}
|
apache/ignite-3 | 1,113 | modules/sql-engine/src/integrationTest/java/org/apache/ignite/internal/sql/engine/ItNotNullConstraintServerTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.sql.engine;
import org.apache.ignite.Ignite;
/**
* NOT NULL constraint test for server/embedded API.
*/
public class ItNotNullConstraintServerTest extends ItNotNullConstraintTest {
@Override
protected Ignite ignite() {
return CLUSTER.aliveNode();
}
}
|
apache/ignite-3 | 1,126 | modules/network/src/test/resources/org/apache/ignite/internal/network/processor/ConflictingTypeMessage.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.network.processor;
import java.util.Collection;
import org.apache.ignite.internal.network.NetworkMessage;
import org.apache.ignite.internal.network.annotations.Transferable;
@Transferable(1)
public interface ConflictingTypeMessage extends NetworkMessage {
Collection<Integer> a();
}
|
apache/ignite-3 | 1,130 | modules/sql-engine/src/main/java/org/apache/ignite/internal/sql/engine/sql/IgniteSqlIndexType.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.sql.engine.sql;
/**
* Enumeration of supported index types.
*/
public enum IgniteSqlIndexType {
/** Sorted index. */
SORTED,
/** Hash index. */
HASH,
/** The user have omitted USING clause, hence the type is set to {@link #SORTED} implicitly. */
IMPLICIT_SORTED
}
|
apache/ignite-3 | 1,133 | modules/cli/src/main/java/org/apache/ignite/internal/cli/core/repl/registry/UnitsRegistry.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.registry;
import java.util.Set;
/** Deployed units registry. */
public interface UnitsRegistry {
/** Versions of the unit by id. */
Set<String> versions(String unitId);
/** All unit ids. */
Set<String> ids();
/** Refresh the state. */
void refresh();
}
|
apache/ignite-3 | 1,150 | modules/raft/src/main/java/org/apache/ignite/raft/jraft/util/RecycleUtil.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.raft.jraft.util;
/**
* Recycle tool for {@link Recyclable}.
*/
public final class RecycleUtil {
/**
* Recycle designated instance.
*/
public static boolean recycle(final Object obj) {
return obj instanceof Recyclable && ((Recyclable) obj).recycle();
}
private RecycleUtil() {
}
}
|
apache/incubator-brooklyn | 1,116 | brooklyn-library/software/messaging/src/main/java/org/apache/brooklyn/entity/messaging/qpid/QpidQueue.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 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.messaging.qpid;
import org.apache.brooklyn.api.entity.ImplementedBy;
import org.apache.brooklyn.entity.messaging.Queue;
@ImplementedBy(QpidQueueImpl.class)
public interface QpidQueue extends QpidDestination, Queue {
@Override
public String getExchangeName();
}
|
apache/incubator-datalab | 1,126 | services/self-service/src/main/java/com/epam/datalab/backendapi/domain/ProjectEndpointDTO.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package com.epam.datalab.backendapi.domain;
import com.epam.datalab.dto.UserInstanceStatus;
import com.epam.datalab.dto.base.edge.EdgeInfo;
import lombok.Data;
@Data
public class ProjectEndpointDTO {
private final String name;
private final UserInstanceStatus status;
private final EdgeInfo edgeInfo;
}
|
apache/incubator-gluten | 1,132 | backends-velox/src-iceberg-spark34/test/java/org/apache/gluten/sql/TestGlutenDeleteFrom.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.gluten.sql;
import org.apache.iceberg.spark.sql.TestDeleteFrom;
import java.util.Map;
public class TestGlutenDeleteFrom extends TestDeleteFrom {
public TestGlutenDeleteFrom(
String catalogName, String implementation, Map<String, String> config) {
super(catalogName, implementation, config);
}
}
|
apache/incubator-hugegraph-computer | 1,105 | computer/computer-test/src/main/java/org/apache/hugegraph/computer/core/sort/sorter/SorterTestSuite.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with this
* work for additional information regarding copyright ownership. The ASF
* licenses this file to You under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*/
package org.apache.hugegraph.computer.core.sort.sorter;
import org.junit.runner.RunWith;
import org.junit.runners.Suite;
@RunWith(Suite.class)
@Suite.SuiteClasses({
FlusherTest.class,
SortLargeDataTest.class,
SorterTest.class,
EmptyFlusherTest.class
})
public class SorterTestSuite {
}
|
apache/incubator-hugegraph-toolchain | 1,120 | hugegraph-client/src/main/java/org/apache/hugegraph/structure/auth/LoginResult.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with this
* work for additional information regarding copyright ownership. The ASF
* licenses this file to You under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*/
package org.apache.hugegraph.structure.auth;
import com.fasterxml.jackson.annotation.JsonProperty;
public class LoginResult {
@JsonProperty("token")
private String token;
public void token(String token) {
this.token = token;
}
public String token() {
return this.token;
}
}
|
apache/incubator-hugegraph | 1,124 | hugegraph-pd/hg-pd-test/src/main/java/org/apache/hugegraph/pd/client/PDClientSuiteTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.hugegraph.pd.client;
import org.junit.runner.RunWith;
import org.junit.runners.Suite;
import lombok.extern.slf4j.Slf4j;
@RunWith(Suite.class)
@Suite.SuiteClasses({
PDClientTest.class,
KvClientTest.class,
StoreRegisterTest.class,
})
@Slf4j
public class PDClientSuiteTest {
}
|
apache/incubator-kie-drools | 1,106 | drools-persistence/drools-persistence-api/src/main/java/org/drools/persistence/api/SessionNotFoundException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.persistence.api;
public class SessionNotFoundException extends RuntimeException {
public SessionNotFoundException(String message) {
super(message);
}
public SessionNotFoundException(String message, Exception cause) {
super(message, cause);
}
}
|
apache/incubator-kie-drools | 1,135 | kie-internal/src/main/java/org/kie/internal/builder/JaxbConfiguration.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.internal.builder;
import java.util.List;
import com.sun.tools.xjc.Options;
import org.kie.api.io.ResourceConfiguration;
public interface JaxbConfiguration
extends
ResourceConfiguration {
public Options getXjcOpts();
public String getSystemId();
public List<String> getClasses();
}
|
apache/incubator-kie-drools | 1,135 | kie-internal/src/main/java/org/kie/internal/ruleunit/RuleUnitVariable.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.internal.ruleunit;
import java.lang.reflect.Type;
public interface RuleUnitVariable {
boolean isDataSource();
boolean isDataStore();
String getName();
String getter();
String setter();
Type getType();
Class<?> getDataSourceParameterType();
Class<?> getBoxedVarType();
}
|
apache/incubator-kie-kogito-apps | 1,048 | persistence-commons/persistence-commons-reporting-parent/persistence-commons-reporting-api/src/main/java/org/kie/kogito/persistence/reporting/model/PartitionField.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.persistence.reporting.model;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
@JsonIgnoreProperties(ignoreUnknown = true)
public interface PartitionField extends Field {
String getFieldValue();
}
|
apache/incubator-kie-kogito-apps | 1,089 | jobs-service/jobs-service-common/src/main/java/org/kie/kogito/jobs/service/resource/error/IllegalArgumentExceptionMapper.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.jobs.service.resource.error;
import jakarta.ws.rs.ext.Provider;
@Provider
public class IllegalArgumentExceptionMapper extends BaseExceptionMapper<IllegalArgumentException> {
public IllegalArgumentExceptionMapper() {
super(400, false);
}
}
|
apache/incubator-kie-kogito-apps | 1,091 | data-index/data-index-storage/data-index-storage-jpa/src/test/java/org/kie/kogito/index/jdbc/query/H2JobEntityQueryIT.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.index.jdbc.query;
import org.kie.kogito.index.jpa.query.AbstractJobEntityQueryIT;
import io.quarkus.test.TestTransaction;
import io.quarkus.test.junit.QuarkusTest;
@QuarkusTest
@TestTransaction
class H2JobEntityQueryIT extends AbstractJobEntityQueryIT {
}
|
apache/incubator-kie-kogito-apps | 1,111 | data-index/data-index-common/src/main/java/org/kie/kogito/index/service/DataIndexServiceException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.index.service;
public class DataIndexServiceException extends RuntimeException {
public DataIndexServiceException(String message) {
super(message);
}
public DataIndexServiceException(String message, Throwable cause) {
super(message, cause);
}
}
|
apache/incubator-kie-kogito-runtimes | 1,092 | kogito-codegen-modules/kogito-codegen-predictions/src/main/resources/class-templates/PredictionModelsSpringTemplate.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package $Package$;
@org.springframework.stereotype.Component
@org.springframework.web.context.annotation.ApplicationScope
public class PredictionModels extends org.kie.kogito.pmml.AbstractPredictionModels {
static {
init(/* arguments provided during codegen */);
}
} |
apache/incubator-kie-kogito-runtimes | 1,125 | drools/kogito-drools/src/main/java/org/kie/kogito/rules/RuleEventListenerConfig.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR 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.rules;
import java.util.List;
import org.kie.api.event.rule.AgendaEventListener;
import org.kie.api.event.rule.RuleRuntimeEventListener;
public interface RuleEventListenerConfig {
List<AgendaEventListener> agendaListeners();
List<RuleRuntimeEventListener> ruleRuntimeListeners();
}
|
apache/incubator-myriad | 1,126 | myriad-scheduler/src/main/java/org/apache/myriad/scheduler/event/ReRegisteredEventFactory.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.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;
/**
* Mesos re-register event factory
*/
public class ReRegisteredEventFactory implements EventFactory<ReRegisteredEvent> {
@Override
public ReRegisteredEvent newInstance() {
return new ReRegisteredEvent();
}
}
|
apache/incubator-nemo | 1,143 | common/src/main/java/org/apache/nemo/common/exception/ContainerException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.nemo.common.exception;
/**
* ContainerException.
* Thrown for container/resource related exceptions.
*/
public final class ContainerException extends RuntimeException {
/**
* ContainerException.
*
* @param cause cause
*/
public ContainerException(final Throwable cause) {
super(cause);
}
}
|
apache/incubator-seata | 1,126 | config/seata-config-core/src/main/java/org/apache/seata/config/ConfigurationChangeType.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.seata.config;
/**
* The enum Configuration change type.
*
*/
public enum ConfigurationChangeType {
/**
* Add configuration change type.
*/
ADD,
/**
* Modify configuration change type.
*/
MODIFY,
/**
* Delete configuration change type.
*/
DELETE
}
|
apache/incubator-seata | 1,134 | rm-datasource/src/test/java/org/apache/seata/rm/datasource/undo/h2/keyword/H2EscapeHandler.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.seata.rm.datasource.undo.h2.keyword;
import org.apache.seata.common.loader.LoadLevel;
import org.apache.seata.rm.datasource.sql.handler.mysql.MySQLEscapeHandler;
import org.apache.seata.sqlparser.util.JdbcConstants;
@LoadLevel(name = JdbcConstants.H2)
public class H2EscapeHandler extends MySQLEscapeHandler {}
|
apache/incubator-seata | 1,135 | server/src/main/java/org/apache/seata/server/coordinator/TransactionCoordinatorInbound.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.seata.server.coordinator;
import org.apache.seata.core.model.ResourceManagerOutbound;
import org.apache.seata.core.model.TransactionManager;
/**
* receive inbound request from RM or TM.
*
* @since 1.1.0
*/
public interface TransactionCoordinatorInbound extends ResourceManagerOutbound, TransactionManager {}
|
apache/iotdb-extras | 1,111 | iotdb-collector/collector-core/src/main/java/org/apache/iotdb/collector/runtime/task/event/EventContainer.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 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.collector.runtime.task.event;
import org.apache.iotdb.pipe.api.event.Event;
public class EventContainer implements Event {
private Event event;
public Event getEvent() {
return event;
}
public void setEvent(final Event event) {
this.event = event;
}
}
|
apache/iotdb | 1,137 | iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/consensus/ConfigRegionId.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 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.consensus;
import org.apache.iotdb.common.rpc.thrift.TConsensusGroupType;
public class ConfigRegionId extends ConsensusGroupId {
public ConfigRegionId(int id) {
this.id = id;
}
@Override
public TConsensusGroupType getType() {
return TConsensusGroupType.ConfigRegion;
}
}
|
apache/iotdb | 1,137 | iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/consensus/SchemaRegionId.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 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.consensus;
import org.apache.iotdb.common.rpc.thrift.TConsensusGroupType;
public class SchemaRegionId extends ConsensusGroupId {
public SchemaRegionId(int id) {
this.id = id;
}
@Override
public TConsensusGroupType getType() {
return TConsensusGroupType.SchemaRegion;
}
}
|
apache/jclouds | 1,128 | providers/azureblob/src/main/java/org/jclouds/azureblob/config/InsufficientAccessRightsException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* Handles the inability of SAS Authentication string to authenticate the getAcl and setAcl requests.
*
*/
package org.jclouds.azureblob.config;
public class InsufficientAccessRightsException extends RuntimeException {
public InsufficientAccessRightsException(String message) {
super(message);
}
}
|
apache/jena | 1,138 | jena-db/jena-dboe-storage/src/test/java/org/apache/jena/dboe/storage/prefixes/TS_Prefixes.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.storage.prefixes;
import org.junit.platform.suite.api.SelectClasses;
import org.junit.platform.suite.api.Suite;
@Suite
@SelectClasses({
TestDatasetPrefixesMem.class
, TestPrefixMappingOverDatasetPrefixes.class
, TestPrefixMappingOverDatasetPrefixes2.class
})
public class TS_Prefixes
{}
|
apache/jena | 1,153 | jena-arq/src/test/java/org/apache/jena/sparql/modify/TestUpdateGraphMgtTxnMem.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.sparql.modify;
import org.apache.jena.sparql.core.DatasetGraph;
import org.apache.jena.sparql.core.DatasetGraphFactory;
public class TestUpdateGraphMgtTxnMem extends AbstractTestUpdateGraphMgt {
@Override
protected DatasetGraph getEmptyDatasetGraph() {
return DatasetGraphFactory.createTxnMem();
}
}
|
apache/kafka | 1,152 | clients/src/main/java/org/apache/kafka/common/errors/NotControllerException.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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 NotControllerException extends RetriableException {
private static final long serialVersionUID = 1L;
public NotControllerException(String message) {
super(message);
}
public NotControllerException(String message, Throwable cause) {
super(message, cause);
}
}
|
apache/kylin | 1,159 | src/core-common/src/main/java/org/apache/kylin/common/util/MathUtil.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.common.util;
import java.util.List;
public class MathUtil {
public static double findMedianInSortedList(List<Double> m) {
int middle = m.size() / 2;
if (m.size() % 2 == 1) {
return m.get(middle);
} else {
return (m.get(middle - 1) + m.get(middle)) / 2.0;
}
}
}
|
apache/linkis | 1,127 | linkis-public-enhancements/linkis-pes-common/src/main/java/org/apache/linkis/cs/listener/CSIDListener.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.linkis.cs.listener;
import org.apache.linkis.cs.listener.event.ContextIDEvent;
public interface CSIDListener extends ContextAsyncEventListener {
void onCSIDAccess(ContextIDEvent contextIDEvent);
void onCSIDADD(ContextIDEvent contextIDEvent);
void onCSIDRemoved(ContextIDEvent contextIDEvent);
}
|
apache/lucene | 1,136 | lucene/analysis/common/src/test/org/apache/lucene/analysis/hunspell/TestCondition2.java | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.lucene.analysis.hunspell;
import org.junit.BeforeClass;
public class TestCondition2 extends StemmerTestBase {
@BeforeClass
public static void beforeClass() throws Exception {
init("condition2.aff", "condition2.dic");
}
public void testStemming() {
assertStemsTo("monopolies", "monopoly");
}
}
|
apache/metron | 1,120 | metron-interface/metron-rest-client/src/main/java/org/apache/metron/rest/model/pcap/QueryPcapOptions.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS 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.rest.model.pcap;
import org.apache.metron.common.configuration.ConfigOption;
public enum QueryPcapOptions implements ConfigOption {
QUERY("query");
String key;
QueryPcapOptions(String key) {
this.key = key;
}
@Override
public String getKey() {
return key;
}
}
|
apache/mina-ftpserver | 1,144 | core/src/test/java/org/apache/ftpserver/ssl/MinaExplicitSSLTest.java | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.ftpserver.ssl;
import org.junit.Ignore;
/**
*
* @author <a href="http://mina.apache.org">Apache MINA Project</a>
*
*/
@Ignore( "SSL V3 not supported anymore" )
public class MinaExplicitSSLTest extends ExplicitSecurityTestTemplate {
@Override
protected String getAuthValue() {
return "SSL";
}
}
|
apache/oozie | 1,163 | core/src/main/java/org/apache/oozie/util/graph/GraphRenderer.java | /**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.oozie.util.graph;
import java.awt.image.BufferedImage;
public interface GraphRenderer {
void addNode(WorkflowActionNode node);
void addEdge(WorkflowActionNode parent, WorkflowActionNode child);
void persist(WorkflowActionNode parent);
BufferedImage renderPng();
String renderDot();
String renderSvg();
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.