code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
public static xen_hotfix[] apply(nitro_service client, xen_hotfix[] resources) throws Exception
{
if(resources == null)
throw new Exception("Null resource array");
if(resources.length == 1)
return ((xen_hotfix[]) resources[0].perform_operation(client, "apply"));
return ((xen_hotfix[]) perform... | class class_name[name] begin[{]
method[apply, return_type[type[xen_hotfix]], modifier[public static], parameter[client, resources]] begin[{]
if[binary_operation[member[.resources], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefi... | Keyword[public] Keyword[static] identifier[xen_hotfix] operator[SEP] operator[SEP] identifier[apply] operator[SEP] identifier[nitro_service] identifier[client] , identifier[xen_hotfix] operator[SEP] operator[SEP] identifier[resources] operator[SEP] Keyword[throws] identifier[Exception] {
Keyword[if] operator[SE... |
public static WriteConcernResult unacknowledged() {
return new WriteConcernResult() {
@Override
public boolean wasAcknowledged() {
return false;
}
@Override
public int getCount() {
throw getUnacknowledgedWriteException(... | class class_name[name] begin[{]
method[unacknowledged, return_type[type[WriteConcernResult]], modifier[public static], parameter[]] begin[{]
return[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[ReturnStatement(expression=Literal(postfix_... | Keyword[public] Keyword[static] identifier[WriteConcernResult] identifier[unacknowledged] operator[SEP] operator[SEP] {
Keyword[return] Keyword[new] identifier[WriteConcernResult] operator[SEP] operator[SEP] {
annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[wasAcknowledg... |
private short subcolor(int c, int rangeCount) throws RegexException {
short co; /* current color of c */
short sco; /* new subcolor */
co = getcolor(c);
sco = newsub(co);
assert sco != Constants.COLORLESS;
if (co == sco) /* already in an open sub... | class class_name[name] begin[{]
method[subcolor, return_type[type[short]], modifier[private], parameter[c, rangeCount]] begin[{]
local_variable[type[short], co]
local_variable[type[short], sco]
assign[member[.co], call[.getcolor, parameter[member[.c]]]]
assign[me... | Keyword[private] Keyword[short] identifier[subcolor] operator[SEP] Keyword[int] identifier[c] , Keyword[int] identifier[rangeCount] operator[SEP] Keyword[throws] identifier[RegexException] {
Keyword[short] identifier[co] operator[SEP] Keyword[short] identifier[sco] operator[SEP] identifier[co] operator[=] ident... |
public ListIterator<IWord> findFirstWordIteratorByLabel(String label)
{
ListIterator<IWord> listIterator = this.wordList.listIterator();
while (listIterator.hasNext())
{
IWord word = listIterator.next();
if (label.equals(word.getLabel()))
{
... | class class_name[name] begin[{]
method[findFirstWordIteratorByLabel, return_type[type[ListIterator]], modifier[public], parameter[label]] begin[{]
local_variable[type[ListIterator], listIterator]
while[call[listIterator.hasNext, parameter[]]] begin[{]
local_variable[type[IWo... | Keyword[public] identifier[ListIterator] operator[<] identifier[IWord] operator[>] identifier[findFirstWordIteratorByLabel] operator[SEP] identifier[String] identifier[label] operator[SEP] {
identifier[ListIterator] operator[<] identifier[IWord] operator[>] identifier[listIterator] operator[=] Keyword[this] oper... |
public DescribeEventsResult withEvents(Event... events) {
if (this.events == null) {
setEvents(new java.util.ArrayList<Event>(events.length));
}
for (Event ele : events) {
this.events.add(ele);
}
return this;
} | class class_name[name] begin[{]
method[withEvents, return_type[type[DescribeEventsResult]], modifier[public], parameter[events]] begin[{]
if[binary_operation[THIS[member[None.events]], ==, literal[null]]] begin[{]
call[.setEvents, parameter[ClassCreator(arguments=[Member... | Keyword[public] identifier[DescribeEventsResult] identifier[withEvents] operator[SEP] identifier[Event] operator[...] identifier[events] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[events] operator[==] Other[null] operator[SEP] {
identifier[setEvents] operator[SEP]... |
public void marshall(UpdatePipelineRequest updatePipelineRequest, ProtocolMarshaller protocolMarshaller) {
if (updatePipelineRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(updatePipelineRe... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[updatePipelineRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.updatePipelineRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Lit... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[UpdatePipelineRequest] identifier[updatePipelineRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[updatePipelineRequest] operator[==] Other[null] operator[SEP] ... |
public static final void writeUTF(OutputStream out,
char[] chars, int offset, int length)
throws IOException
{
for (int i=0; i<length; i++) {
int c = chars[i + offset];
if ((c >= 0x0001) && (c <= 0x007F)) {
out.write(c);
... | class class_name[name] begin[{]
method[writeUTF, return_type[void], modifier[final public static], parameter[out, chars, offset, length]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer... | Keyword[public] Keyword[static] Keyword[final] Keyword[void] identifier[writeUTF] operator[SEP] identifier[OutputStream] identifier[out] , Keyword[char] operator[SEP] operator[SEP] identifier[chars] , Keyword[int] identifier[offset] , Keyword[int] identifier[length] operator[SEP] Keyword[throws] identifier[IOExcepti... |
@Requires({
"contextLocal >= 0",
"checkInvariantsLocal >= 0"
})
@Ensures("result != null")
protected Label enterBusySection() {
Label skip = new Label();
loadLocal(contextLocal);
invokeVirtual(CONTRACT_CONTEXT_TYPE, TRY_ENTER_CONTRACT_METHOD);
ifZCmp(EQ, skip);
return skip;
} | class class_name[name] begin[{]
method[enterBusySection, return_type[type[Label]], modifier[protected], parameter[]] begin[{]
local_variable[type[Label], skip]
call[.loadLocal, parameter[member[.contextLocal]]]
call[.invokeVirtual, parameter[member[.CONTRACT_CONTEXT_TYPE... | annotation[@] identifier[Requires] operator[SEP] {
literal[String] , literal[String]
} operator[SEP] annotation[@] identifier[Ensures] operator[SEP] literal[String] operator[SEP] Keyword[protected] identifier[Label] identifier[enterBusySection] operator[SEP] operator[SEP] {
identifier[Label] identifie... |
@Override
public void commitBlobBlocks(String blob, BlockList blockList)
throws ServiceException {
blobService.commitBlobBlocks(containerName, blob, blockList);
} | class class_name[name] begin[{]
method[commitBlobBlocks, return_type[void], modifier[public], parameter[blob, blockList]] begin[{]
call[blobService.commitBlobBlocks, parameter[member[.containerName], member[.blob], member[.blockList]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[commitBlobBlocks] operator[SEP] identifier[String] identifier[blob] , identifier[BlockList] identifier[blockList] operator[SEP] Keyword[throws] identifier[ServiceException] {
identifier[blobService] operator[SEP] identifier[commitBlobBl... |
public static int countMatches(final CharSequence str, final CharSequence sub) {
if (isEmpty(str) || isEmpty(sub)) {
return 0;
}
int count = 0;
int idx = 0;
while ((idx = CharSequenceUtils.indexOf(str, sub, idx)) != INDEX_NOT_FOUND) {
count++;
... | class class_name[name] begin[{]
method[countMatches, return_type[type[int]], modifier[public static], parameter[str, sub]] begin[{]
if[binary_operation[call[.isEmpty, parameter[member[.str]]], ||, call[.isEmpty, parameter[member[.sub]]]]] begin[{]
return[literal[0]]
else beg... | Keyword[public] Keyword[static] Keyword[int] identifier[countMatches] operator[SEP] Keyword[final] identifier[CharSequence] identifier[str] , Keyword[final] identifier[CharSequence] identifier[sub] operator[SEP] {
Keyword[if] operator[SEP] identifier[isEmpty] operator[SEP] identifier[str] operator[SEP] operator... |
public <T extends Evaluation> T evaluate(DataSetIterator iterator) {
return (T)evaluate(iterator, (List<String>)null);
} | class class_name[name] begin[{]
method[evaluate, return_type[type[T]], modifier[public], parameter[iterator]] begin[{]
return[Cast(expression=MethodInvocation(arguments=[MemberReference(member=iterator, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), Cast(expression=Literal(postfi... | Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[Evaluation] operator[>] identifier[T] identifier[evaluate] operator[SEP] identifier[DataSetIterator] identifier[iterator] operator[SEP] {
Keyword[return] operator[SEP] identifier[T] operator[SEP] identifier[evaluate] operator[SEP] identifier[i... |
@WorkerThread
public static CommandResult run(@NonNull String shell, @NonNull String[] commands, @Nullable String[] env) {
List<String> stdout = Collections.synchronizedList(new ArrayList<String>());
List<String> stderr = Collections.synchronizedList(new ArrayList<String>());
int exitCode;
try {
... | class class_name[name] begin[{]
method[run, return_type[type[CommandResult]], modifier[public static], parameter[shell, commands, env]] begin[{]
local_variable[type[List], stdout]
local_variable[type[List], stderr]
local_variable[type[int], exitCode]
TryStatement(block=[LocalVar... | annotation[@] identifier[WorkerThread] Keyword[public] Keyword[static] identifier[CommandResult] identifier[run] operator[SEP] annotation[@] identifier[NonNull] identifier[String] identifier[shell] , annotation[@] identifier[NonNull] identifier[String] operator[SEP] operator[SEP] identifier[commands] , annotation[@] ... |
protected JSONObject toReponsiveImageSource(Media media, MediaFormat mediaFormat) {
String url = buildDummyImageUrl(mediaFormat);
try {
JSONObject source = new JSONObject();
source.put(MediaNameConstants.PROP_BREAKPOINT, mediaFormat.getProperties().get(MediaNameConstants.PROP_BREAKPOINT));
sou... | class class_name[name] begin[{]
method[toReponsiveImageSource, return_type[type[JSONObject]], modifier[protected], parameter[media, mediaFormat]] begin[{]
local_variable[type[String], url]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[]... | Keyword[protected] identifier[JSONObject] identifier[toReponsiveImageSource] operator[SEP] identifier[Media] identifier[media] , identifier[MediaFormat] identifier[mediaFormat] operator[SEP] {
identifier[String] identifier[url] operator[=] identifier[buildDummyImageUrl] operator[SEP] identifier[mediaFormat] ope... |
public Observable<WebhookInner> getAsync(String resourceGroupName, String registryName, String webhookName) {
return getWithServiceResponseAsync(resourceGroupName, registryName, webhookName).map(new Func1<ServiceResponse<WebhookInner>, WebhookInner>() {
@Override
public WebhookInner call... | class class_name[name] begin[{]
method[getAsync, return_type[type[Observable]], modifier[public], parameter[resourceGroupName, registryName, webhookName]] begin[{]
return[call[.getWithServiceResponseAsync, parameter[member[.resourceGroupName], member[.registryName], member[.webhookName]]]]
end[}]
E... | Keyword[public] identifier[Observable] operator[<] identifier[WebhookInner] operator[>] identifier[getAsync] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[registryName] , identifier[String] identifier[webhookName] operator[SEP] {
Keyword[return] identifier[getWi... |
public static boolean isInVpc(InstanceInfo instanceInfo) {
if (instanceInfo.getDataCenterInfo() instanceof AmazonInfo) {
AmazonInfo info = (AmazonInfo) instanceInfo.getDataCenterInfo();
String vpcId = info.get(AmazonInfo.MetaDataKey.vpcId);
return !isNullOrEmpty(vpcId);
... | class class_name[name] begin[{]
method[isInVpc, return_type[type[boolean]], modifier[public static], parameter[instanceInfo]] begin[{]
if[binary_operation[call[instanceInfo.getDataCenterInfo, parameter[]], instanceof, type[AmazonInfo]]] begin[{]
local_variable[type[AmazonInfo], info... | Keyword[public] Keyword[static] Keyword[boolean] identifier[isInVpc] operator[SEP] identifier[InstanceInfo] identifier[instanceInfo] operator[SEP] {
Keyword[if] operator[SEP] identifier[instanceInfo] operator[SEP] identifier[getDataCenterInfo] operator[SEP] operator[SEP] Keyword[instanceof] identifier[AmazonInfo... |
public boolean isPoint(){
if (start == null || end == null) {
return false;
}
return start.compareTo(end) == 0 && isStartInclusive && isEndInclusive;
} | class class_name[name] begin[{]
method[isPoint, return_type[type[boolean]], modifier[public], parameter[]] begin[{]
if[binary_operation[binary_operation[member[.start], ==, literal[null]], ||, binary_operation[member[.end], ==, literal[null]]]] begin[{]
return[literal[false]]
... | Keyword[public] Keyword[boolean] identifier[isPoint] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[start] operator[==] Other[null] operator[||] identifier[end] operator[==] Other[null] operator[SEP] {
Keyword[return] literal[boolean] operator[SEP]
}
Keyword[return] i... |
public static void deepCopy(Object src, Object dest) {
Class<?> srcClass = src.getClass();
Preconditions.checkArgument(srcClass == dest.getClass());
if (srcClass.isArray()) {
// clone array
Preconditions.checkArgument(Array.getLength(src) == Array.getLength(dest));
int index = 0;
for... | class class_name[name] begin[{]
method[deepCopy, return_type[void], modifier[public static], parameter[src, dest]] begin[{]
local_variable[type[Class], srcClass]
call[Preconditions.checkArgument, parameter[binary_operation[member[.srcClass], ==, call[dest.getClass, parameter[]]]]]
... | Keyword[public] Keyword[static] Keyword[void] identifier[deepCopy] operator[SEP] identifier[Object] identifier[src] , identifier[Object] identifier[dest] operator[SEP] {
identifier[Class] operator[<] operator[?] operator[>] identifier[srcClass] operator[=] identifier[src] operator[SEP] identifier[getClass] oper... |
protected void connectBottom(GrayS32 input, GrayS32 output) {
for( int x = 0; x < input.width-1; x++ ) {
int y = input.height-1;
int inputLabel = input.unsafe_get(x,y);
int outputLabel = output.unsafe_get(x,y);
if( outputLabel == -1 ) { // see if it needs to create a new output segment
outputLabel =... | class class_name[name] begin[{]
method[connectBottom, return_type[void], modifier[protected], parameter[input, output]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=BinaryOperation(o... | Keyword[protected] Keyword[void] identifier[connectBottom] operator[SEP] identifier[GrayS32] identifier[input] , identifier[GrayS32] identifier[output] operator[SEP] {
Keyword[for] operator[SEP] Keyword[int] identifier[x] operator[=] Other[0] operator[SEP] identifier[x] operator[<] identifier[input] operator[SE... |
protected void increaseEncryptedBuffer() throws IOException {
final int packetSize = getConnLink().getPacketBufferSize();
if (null == this.encryptedAppBuffer) {
if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
Tr.event(tc, "Allocating encryptedAppBuffer, siz... | class class_name[name] begin[{]
method[increaseEncryptedBuffer, return_type[void], modifier[protected], parameter[]] begin[{]
local_variable[type[int], packetSize]
if[binary_operation[literal[null], ==, THIS[member[None.encryptedAppBuffer]]]] begin[{]
if[binary_o... | Keyword[protected] Keyword[void] identifier[increaseEncryptedBuffer] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[final] Keyword[int] identifier[packetSize] operator[=] identifier[getConnLink] operator[SEP] operator[SEP] operator[SEP] identifier[getPacketBufferSize] operator[SEP]... |
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case BpsimPackage.NUMERIC_PARAMETER_TYPE__CURRENCY_UNIT:
return getCurrencyUnit();
case BpsimPackage.NUMERIC_PARAMETER_TYPE__TIME_UNIT:
return getTimeUnit();
case BpsimPackage.NUMERIC_PARAMETER_TYPE... | class class_name[name] begin[{]
method[eGet, return_type[type[Object]], modifier[public], parameter[featureID, resolve, coreType]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=[MemberReference(member=NUMERIC_PARAMETER_TYPE__CURRENCY_UNIT, postfix_operators=[], prefix_operators=[], qualifier... | annotation[@] identifier[Override] Keyword[public] identifier[Object] identifier[eGet] operator[SEP] Keyword[int] identifier[featureID] , Keyword[boolean] identifier[resolve] , Keyword[boolean] identifier[coreType] operator[SEP] {
Keyword[switch] operator[SEP] identifier[featureID] operator[SEP] {
K... |
public ConfigDescriptor buildDescriptor(Method method, Optional<String> scopeOpt)
{
return buildDescriptor(method, scopeOpt, Optional.empty());
} | class class_name[name] begin[{]
method[buildDescriptor, return_type[type[ConfigDescriptor]], modifier[public], parameter[method, scopeOpt]] begin[{]
return[call[.buildDescriptor, parameter[member[.method], member[.scopeOpt], call[Optional.empty, parameter[]]]]]
end[}]
END[}] | Keyword[public] identifier[ConfigDescriptor] identifier[buildDescriptor] operator[SEP] identifier[Method] identifier[method] , identifier[Optional] operator[<] identifier[String] operator[>] identifier[scopeOpt] operator[SEP] {
Keyword[return] identifier[buildDescriptor] operator[SEP] identifier[method] , iden... |
public static String replaceWordsIgnoreCase(String input, String[] words, String[] replaces) {
StringBuilder sb = new StringBuilder(input);
replaceWordsIgnoreCase(sb, words, replaces);
return sb.toString();
} | class class_name[name] begin[{]
method[replaceWordsIgnoreCase, return_type[type[String]], modifier[public static], parameter[input, words, replaces]] begin[{]
local_variable[type[StringBuilder], sb]
call[.replaceWordsIgnoreCase, parameter[member[.sb], member[.words], member[.replaces]]]... | Keyword[public] Keyword[static] identifier[String] identifier[replaceWordsIgnoreCase] operator[SEP] identifier[String] identifier[input] , identifier[String] operator[SEP] operator[SEP] identifier[words] , identifier[String] operator[SEP] operator[SEP] identifier[replaces] operator[SEP] {
identifier[StringBuil... |
private static String fixName(String name) {
// convert old-format name to new-format name
if (name.equals("local")) { // "local" is now "file:///".
LOG.warn("\"local\" is a deprecated filesystem name."
+" Use \"file:///\" instead.");
name = "file:///";
} else if (name.ind... | class class_name[name] begin[{]
method[fixName, return_type[type[String]], modifier[private static], parameter[name]] begin[{]
if[call[name.equals, parameter[literal["local"]]]] begin[{]
call[LOG.warn, parameter[binary_operation[literal["\"local\" is a deprecated filesys... | Keyword[private] Keyword[static] identifier[String] identifier[fixName] operator[SEP] identifier[String] identifier[name] operator[SEP] {
Keyword[if] operator[SEP] identifier[name] operator[SEP] identifier[equals] operator[SEP] literal[String] operator[SEP] operator[SEP] {
identifier[LOG] operator[SEP... |
public static void closeQuietly(@Nullable Socket socket, @Nullable Writer writer) {
if (writer != null) {
try {
writer.close();
} catch (IOException e) {
}
}
closeQuietly(socket);
} | class class_name[name] begin[{]
method[closeQuietly, return_type[void], modifier[public static], parameter[socket, writer]] begin[{]
if[binary_operation[member[.writer], !=, literal[null]]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[], me... | Keyword[public] Keyword[static] Keyword[void] identifier[closeQuietly] operator[SEP] annotation[@] identifier[Nullable] identifier[Socket] identifier[socket] , annotation[@] identifier[Nullable] identifier[Writer] identifier[writer] operator[SEP] {
Keyword[if] operator[SEP] identifier[writer] operator[!=] Other... |
public String substring(final int startIndex, int endIndex) {
endIndex = validateRange(startIndex, endIndex);
return new String(buffer, startIndex, endIndex - startIndex);
} | class class_name[name] begin[{]
method[substring, return_type[type[String]], modifier[public], parameter[startIndex, endIndex]] begin[{]
assign[member[.endIndex], call[.validateRange, parameter[member[.startIndex], member[.endIndex]]]]
return[ClassCreator(arguments=[MemberReference(memb... | Keyword[public] identifier[String] identifier[substring] operator[SEP] Keyword[final] Keyword[int] identifier[startIndex] , Keyword[int] identifier[endIndex] operator[SEP] {
identifier[endIndex] operator[=] identifier[validateRange] operator[SEP] identifier[startIndex] , identifier[endIndex] operator[SEP] oper... |
public <T extends OmiseObject> T deserialize(InputStream input, TypeReference<T> ref) throws IOException {
return objectMapper.readerFor(ref).readValue(input);
} | class class_name[name] begin[{]
method[deserialize, return_type[type[T]], modifier[public], parameter[input, ref]] begin[{]
return[call[objectMapper.readerFor, parameter[member[.ref]]]]
end[}]
END[}] | Keyword[public] operator[<] identifier[T] Keyword[extends] identifier[OmiseObject] operator[>] identifier[T] identifier[deserialize] operator[SEP] identifier[InputStream] identifier[input] , identifier[TypeReference] operator[<] identifier[T] operator[>] identifier[ref] operator[SEP] Keyword[throws] identifier[IOExcep... |
public static String getURI(Attributes attrs) {
String src = attrs.getValue(URI, SRC_ATTR);
return src != null ? src : LocationUtils.UNKNOWN_STRING;
} | class class_name[name] begin[{]
method[getURI, return_type[type[String]], modifier[public static], parameter[attrs]] begin[{]
local_variable[type[String], src]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=src, postfix_operators=[], prefix_operators=[], qual... | Keyword[public] Keyword[static] identifier[String] identifier[getURI] operator[SEP] identifier[Attributes] identifier[attrs] operator[SEP] {
identifier[String] identifier[src] operator[=] identifier[attrs] operator[SEP] identifier[getValue] operator[SEP] identifier[URI] , identifier[SRC_ATTR] operator[SEP] oper... |
public Integer getPartition() {
Object partition = getHeader(KafkaMessageHeaders.PARTITION);
if (partition != null) {
return TypeConversionUtils.convertIfNecessary(partition, Integer.class);
}
return null;
} | class class_name[name] begin[{]
method[getPartition, return_type[type[Integer]], modifier[public], parameter[]] begin[{]
local_variable[type[Object], partition]
if[binary_operation[member[.partition], !=, literal[null]]] begin[{]
return[call[TypeConversionUtils.convertIfNece... | Keyword[public] identifier[Integer] identifier[getPartition] operator[SEP] operator[SEP] {
identifier[Object] identifier[partition] operator[=] identifier[getHeader] operator[SEP] identifier[KafkaMessageHeaders] operator[SEP] identifier[PARTITION] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[... |
public EClass getIfcBooleanOperand() {
if (ifcBooleanOperandEClass == null) {
ifcBooleanOperandEClass = (EClass) EPackage.Registry.INSTANCE.getEPackage(Ifc2x3tc1Package.eNS_URI)
.getEClassifiers().get(939);
}
return ifcBooleanOperandEClass;
} | class class_name[name] begin[{]
method[getIfcBooleanOperand, return_type[type[EClass]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.ifcBooleanOperandEClass], ==, literal[null]]] begin[{]
assign[member[.ifcBooleanOperandEClass], Cast(expression=Met... | Keyword[public] identifier[EClass] identifier[getIfcBooleanOperand] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[ifcBooleanOperandEClass] operator[==] Other[null] operator[SEP] {
identifier[ifcBooleanOperandEClass] operator[=] operator[SEP] identifier[EClass] operator[SEP] identi... |
public <T> void register(Class<T> type, Converter<T> converter) {
addConverter(type, converter);
} | class class_name[name] begin[{]
method[register, return_type[void], modifier[public], parameter[type, converter]] begin[{]
call[.addConverter, parameter[member[.type], member[.converter]]]
end[}]
END[}] | Keyword[public] operator[<] identifier[T] operator[>] Keyword[void] identifier[register] operator[SEP] identifier[Class] operator[<] identifier[T] operator[>] identifier[type] , identifier[Converter] operator[<] identifier[T] operator[>] identifier[converter] operator[SEP] {
identifier[addConverter] operator[SE... |
@Override
public List<DistinctQueryResult> divide() {
return Lists.newArrayList(Iterators.transform(getResultData(), new Function<QueryRow, DistinctQueryResult>() {
@Override
public DistinctQueryResult apply(final QueryRow input) {
Set<QueryRow> resultData = new ... | class class_name[name] begin[{]
method[divide, return_type[type[List]], modifier[public], parameter[]] begin[{]
return[call[Lists.newArrayList, parameter[call[Iterators.transform, parameter[call[.getResultData, parameter[]], ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(ele... | annotation[@] identifier[Override] Keyword[public] identifier[List] operator[<] identifier[DistinctQueryResult] operator[>] identifier[divide] operator[SEP] operator[SEP] {
Keyword[return] identifier[Lists] operator[SEP] identifier[newArrayList] operator[SEP] identifier[Iterators] operator[SEP] identifier[transf... |
static void capturePageEvent(String eventName, final EventHandler handler) {
HtmlPlatform.captureEvent(eventName, new EventHandler() {
@Override
public void handleEvent(NativeEvent evt) {
handler.handleEvent(evt);
}
});
} | class class_name[name] begin[{]
method[capturePageEvent, return_type[void], modifier[static], parameter[eventName, handler]] begin[{]
call[HtmlPlatform.captureEvent, parameter[member[.eventName], ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Overr... | Keyword[static] Keyword[void] identifier[capturePageEvent] operator[SEP] identifier[String] identifier[eventName] , Keyword[final] identifier[EventHandler] identifier[handler] operator[SEP] {
identifier[HtmlPlatform] operator[SEP] identifier[captureEvent] operator[SEP] identifier[eventName] , Keyword[new] iden... |
protected final int keyToIndex (int key)
{
// we lift the hash-fixing function from HashMap because Sun
// wasn't kind enough to make it public
key += ~(key << 9);
key ^= (key >>> 14);
key += (key << 4);
key ^= (key >>> 10);
return key & (_buckets.length - ... | class class_name[name] begin[{]
method[keyToIndex, return_type[type[int]], modifier[final protected], parameter[key]] begin[{]
assign[member[.key], binary_operation[member[.key], <<, literal[9]]]
assign[member[.key], binary_operation[member[.key], >>>, literal[14]]]
... | Keyword[protected] Keyword[final] Keyword[int] identifier[keyToIndex] operator[SEP] Keyword[int] identifier[key] operator[SEP] {
identifier[key] operator[+=] operator[~] operator[SEP] identifier[key] operator[<<] Other[9] operator[SEP] operator[SEP] identifier[key] operator[^=] operator[SEP] identifier[key] oper... |
public static Status[] getStatus(String[] pdbIds) {
Status[] statuses = new Status[pdbIds.length];
List<Map<String,String>> attrList = getStatusIdRecords(pdbIds);
//Expect a single record
if(attrList == null || attrList.size() != pdbIds.length) {
logger.error("Error getting Status for {} from the PDB websit... | class class_name[name] begin[{]
method[getStatus, return_type[type[Status]], modifier[public static], parameter[pdbIds]] begin[{]
local_variable[type[Status], statuses]
local_variable[type[List], attrList]
if[binary_operation[binary_operation[member[.attrList], ==, literal[null]... | Keyword[public] Keyword[static] identifier[Status] operator[SEP] operator[SEP] identifier[getStatus] operator[SEP] identifier[String] operator[SEP] operator[SEP] identifier[pdbIds] operator[SEP] {
identifier[Status] operator[SEP] operator[SEP] identifier[statuses] operator[=] Keyword[new] identifier[Status] oper... |
private void replaceForAwaitOf(NodeTraversal t, LexicalContext ctx, Node forAwaitOf) {
int forAwaitId = nextForAwaitId++;
String iteratorTempName = FOR_AWAIT_ITERATOR_TEMP_NAME + forAwaitId;
String resultTempName = FOR_AWAIT_RESULT_TEMP_NAME + forAwaitId;
checkState(forAwaitOf.getParent() != null, "Can... | class class_name[name] begin[{]
method[replaceForAwaitOf, return_type[void], modifier[private], parameter[t, ctx, forAwaitOf]] begin[{]
local_variable[type[int], forAwaitId]
local_variable[type[String], iteratorTempName]
local_variable[type[String], resultTempName]
call[... | Keyword[private] Keyword[void] identifier[replaceForAwaitOf] operator[SEP] identifier[NodeTraversal] identifier[t] , identifier[LexicalContext] identifier[ctx] , identifier[Node] identifier[forAwaitOf] operator[SEP] {
Keyword[int] identifier[forAwaitId] operator[=] identifier[nextForAwaitId] operator[++] opera... |
WaveformPreview getWaveformPreview(int rekordboxId, SlotReference slot, Client client)
throws IOException {
final NumberField idField = new NumberField(rekordboxId);
// First try to get the NXS2-style color waveform if we are supposed to.
if (preferColor.get()) {
try {
... | class class_name[name] begin[{]
method[getWaveformPreview, return_type[type[WaveformPreview]], modifier[default], parameter[rekordboxId, slot, client]] begin[{]
local_variable[type[NumberField], idField]
if[call[preferColor.get, parameter[]]] begin[{]
TryStatement(block=[Loc... | identifier[WaveformPreview] identifier[getWaveformPreview] operator[SEP] Keyword[int] identifier[rekordboxId] , identifier[SlotReference] identifier[slot] , identifier[Client] identifier[client] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[final] identifier[NumberField] identifier[idField] o... |
public JComponent createButtonStack(final Size minimumButtonSize) {
return createButtonStack(minimumButtonSize, GuiStandardUtils.createLeftAndRightBorder(UIConstants.TWO_SPACES));
} | class class_name[name] begin[{]
method[createButtonStack, return_type[type[JComponent]], modifier[public], parameter[minimumButtonSize]] begin[{]
return[call[.createButtonStack, parameter[member[.minimumButtonSize], call[GuiStandardUtils.createLeftAndRightBorder, parameter[member[UIConstants.TWO_SPACES... | Keyword[public] identifier[JComponent] identifier[createButtonStack] operator[SEP] Keyword[final] identifier[Size] identifier[minimumButtonSize] operator[SEP] {
Keyword[return] identifier[createButtonStack] operator[SEP] identifier[minimumButtonSize] , identifier[GuiStandardUtils] operator[SEP] identifier[creat... |
@Override
protected void setConnectionObjectID(int i) {
if (tc.isEntryEnabled())
SibTr.entry(this, tc, "setConnectionObjectID", "" + i);
// Retrieve Client Conversation State if necessary
validateConversationState();
sConState.setConnectionObjectId((short) i);
... | class class_name[name] begin[{]
method[setConnectionObjectID, return_type[void], modifier[protected], parameter[i]] begin[{]
if[call[tc.isEntryEnabled, parameter[]]] begin[{]
call[SibTr.entry, parameter[THIS[], member[.tc], literal["setConnectionObjectID"], binary_operation[literal[... | annotation[@] identifier[Override] Keyword[protected] Keyword[void] identifier[setConnectionObjectID] operator[SEP] Keyword[int] identifier[i] operator[SEP] {
Keyword[if] operator[SEP] identifier[tc] operator[SEP] identifier[isEntryEnabled] operator[SEP] operator[SEP] operator[SEP] identifier[SibTr] operator[SEP... |
int addAll(T... items) {
int positionOfInsert = mObjects.size();
Collections.addAll(mObjects, items);
return positionOfInsert;
} | class class_name[name] begin[{]
method[addAll, return_type[type[int]], modifier[default], parameter[items]] begin[{]
local_variable[type[int], positionOfInsert]
call[Collections.addAll, parameter[member[.mObjects], member[.items]]]
return[member[.positionOfInsert]]
end[}]
EN... | Keyword[int] identifier[addAll] operator[SEP] identifier[T] operator[...] identifier[items] operator[SEP] {
Keyword[int] identifier[positionOfInsert] operator[=] identifier[mObjects] operator[SEP] identifier[size] operator[SEP] operator[SEP] operator[SEP] identifier[Collections] operator[SEP] identifier[addAll] ... |
@OneToMany(targetEntity = org.openprovenance.prov.sql.Type.class, cascade = {
CascadeType.ALL
})
@JoinColumn(name = "TYPE__WASENDEDBY_PK")
public List<org.openprovenance.prov.model.Type> getType() {
if (type == null) {
type=AttributeList.populateKnownAttributes(this,all, org.open... | class class_name[name] begin[{]
method[getType, return_type[type[List]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.type], ==, literal[null]]] begin[{]
assign[member[.type], call[AttributeList.populateKnownAttributes, parameter[THIS[], member[.al... | annotation[@] identifier[OneToMany] operator[SEP] identifier[targetEntity] operator[=] identifier[org] operator[SEP] identifier[openprovenance] operator[SEP] identifier[prov] operator[SEP] identifier[sql] operator[SEP] identifier[Type] operator[SEP] Keyword[class] , identifier[cascade] operator[=] {
identifier[... |
public String commandsWritingDataTo(File dataDirectory) throws IOException {
final Map<DatafileReference, File> refsToFiles = Maps.newHashMap();
for (final DatafileReference datafileReference : datafileReferences) {
final File randomFile = File.createTempFile("plotBundle", ".dat", dataDirectory);
ra... | class class_name[name] begin[{]
method[commandsWritingDataTo, return_type[type[String]], modifier[public], parameter[dataDirectory]] begin[{]
local_variable[type[Map], refsToFiles]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[Var... | Keyword[public] identifier[String] identifier[commandsWritingDataTo] operator[SEP] identifier[File] identifier[dataDirectory] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[final] identifier[Map] operator[<] identifier[DatafileReference] , identifier[File] operator[>] identifier[refsToFiles] op... |
public static DateFormat getBasicDateFormatter() { // PK42263 - made static
// Retrieve a standard Java DateFormat object with desired format, using default locale
return customizeDateFormat(DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM), false);
} | class class_name[name] begin[{]
method[getBasicDateFormatter, return_type[type[DateFormat]], modifier[public static], parameter[]] begin[{]
return[call[.customizeDateFormat, parameter[call[DateFormat.getDateTimeInstance, parameter[member[DateFormat.SHORT], member[DateFormat.MEDIUM]]], literal[false]]]]... | Keyword[public] Keyword[static] identifier[DateFormat] identifier[getBasicDateFormatter] operator[SEP] operator[SEP] {
Keyword[return] identifier[customizeDateFormat] operator[SEP] identifier[DateFormat] operator[SEP] identifier[getDateTimeInstance] operator[SEP] identifier[DateFormat] operator[SEP] identifier[S... |
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
{
switch (featureID)
{
case SimpleExpressionsPackage.IF_CONDITION__CONDITION:
return basicSetCondition(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs... | class class_name[name] begin[{]
method[eInverseRemove, return_type[type[NotificationChain]], modifier[public], parameter[otherEnd, featureID, msgs]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=[MemberReference(member=IF_CONDITION__CONDITION, postfix_operators=[], prefix_operators=[], quali... | annotation[@] identifier[Override] Keyword[public] identifier[NotificationChain] identifier[eInverseRemove] operator[SEP] identifier[InternalEObject] identifier[otherEnd] , Keyword[int] identifier[featureID] , identifier[NotificationChain] identifier[msgs] operator[SEP] {
Keyword[switch] operator[SEP] identifi... |
public String cluster() {
if (d1 == 0) {
// Application portion is empty
return null;
} else {
return (dN > 0 && dN == asg.length()) ? asg() : substr(asg, 0, dN);
}
} | class class_name[name] begin[{]
method[cluster, return_type[type[String]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.d1], ==, literal[0]]] begin[{]
return[literal[null]]
else begin[{]
return[TernaryExpression(condition=BinaryOperation(op... | Keyword[public] identifier[String] identifier[cluster] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[d1] operator[==] Other[0] operator[SEP] {
Keyword[return] Other[null] operator[SEP]
}
Keyword[else] {
Keyword[return] operator[SEP] identifier[dN] operator... |
public static Object createOptional(final Object value) {
if ((OPTIONAL_CLASS == null) || (OFNULLABLE == null)) {
throw new IllegalStateException("Unreachable Code executed. You just found a bug. Please report!");
}
try {
return OFNULLABLE.invoke(null, value);
} c... | class class_name[name] begin[{]
method[createOptional, return_type[type[Object]], modifier[public static], parameter[value]] begin[{]
if[binary_operation[binary_operation[member[.OPTIONAL_CLASS], ==, literal[null]], ||, binary_operation[member[.OFNULLABLE], ==, literal[null]]]] begin[{]
... | Keyword[public] Keyword[static] identifier[Object] identifier[createOptional] operator[SEP] Keyword[final] identifier[Object] identifier[value] operator[SEP] {
Keyword[if] operator[SEP] operator[SEP] identifier[OPTIONAL_CLASS] operator[==] Other[null] operator[SEP] operator[||] operator[SEP] identifier[OFNULLABL... |
private static String fetchHttpResponse(URL url) throws IOException {
HttpURLConnection conn = null;
try {
logger.info("fetching from url = " + url);
conn = (HttpURLConnection) url.openConnection();
int response = conn.getResponseCode();
if (response != HttpURLConnection.... | class class_name[name] begin[{]
method[fetchHttpResponse, return_type[type[String]], modifier[private static], parameter[url]] begin[{]
local_variable[type[HttpURLConnection], conn]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[BinaryOperation(operandl=Literal(p... | Keyword[private] Keyword[static] identifier[String] identifier[fetchHttpResponse] operator[SEP] identifier[URL] identifier[url] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[HttpURLConnection] identifier[conn] operator[=] Other[null] operator[SEP] Keyword[try] {
identifier[logger]... |
public final static <R> JoinObservable<R> when(Plan0<R>... plans) {
return from(Observable.create(OperatorJoinPatterns.when(plans)));
} | class class_name[name] begin[{]
method[when, return_type[type[JoinObservable]], modifier[final public static], parameter[plans]] begin[{]
return[call[.from, parameter[call[Observable.create, parameter[call[OperatorJoinPatterns.when, parameter[member[.plans]]]]]]]]
end[}]
END[}] | Keyword[public] Keyword[final] Keyword[static] operator[<] identifier[R] operator[>] identifier[JoinObservable] operator[<] identifier[R] operator[>] identifier[when] operator[SEP] identifier[Plan0] operator[<] identifier[R] operator[>] operator[...] identifier[plans] operator[SEP] {
Keyword[return] identifier[f... |
public void addHeader(HeaderTypes name, String value) {
headerEntries.add(new HeaderEntry(name.toString(), value));
} | class class_name[name] begin[{]
method[addHeader, return_type[void], modifier[public], parameter[name, value]] begin[{]
call[headerEntries.add, parameter[ClassCreator(arguments=[MethodInvocation(arguments=[], member=toString, postfix_operators=[], prefix_operators=[], qualifier=name, selectors=... | Keyword[public] Keyword[void] identifier[addHeader] operator[SEP] identifier[HeaderTypes] identifier[name] , identifier[String] identifier[value] operator[SEP] {
identifier[headerEntries] operator[SEP] identifier[add] operator[SEP] Keyword[new] identifier[HeaderEntry] operator[SEP] identifier[name] operator[SEP... |
private boolean isSpecialFlagSet(final OptionSet parsedArguments, final String flagName){
if (parsedArguments.has(flagName)){
Object value = parsedArguments.valueOf(flagName);
return (value == null || !value.equals("false"));
} else{
return false;
}
} | class class_name[name] begin[{]
method[isSpecialFlagSet, return_type[type[boolean]], modifier[private], parameter[parsedArguments, flagName]] begin[{]
if[call[parsedArguments.has, parameter[member[.flagName]]]] begin[{]
local_variable[type[Object], value]
return[binary_o... | Keyword[private] Keyword[boolean] identifier[isSpecialFlagSet] operator[SEP] Keyword[final] identifier[OptionSet] identifier[parsedArguments] , Keyword[final] identifier[String] identifier[flagName] operator[SEP] {
Keyword[if] operator[SEP] identifier[parsedArguments] operator[SEP] identifier[has] operator[SEP]... |
public InitiateAuthRequest withAuthParameters(java.util.Map<String, String> authParameters) {
setAuthParameters(authParameters);
return this;
} | class class_name[name] begin[{]
method[withAuthParameters, return_type[type[InitiateAuthRequest]], modifier[public], parameter[authParameters]] begin[{]
call[.setAuthParameters, parameter[member[.authParameters]]]
return[THIS[]]
end[}]
END[}] | Keyword[public] identifier[InitiateAuthRequest] identifier[withAuthParameters] operator[SEP] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[authParameters] operator[SEP] {
identifier[setAuthParameters] oper... |
protected boolean hasIndexProperty(final BeanProperty bp) {
if (bp.bean == null) {
return false;
}
String indexString = extractIndex(bp);
if (indexString == null) {
return hasSimpleProperty(bp);
}
Object resultBean = getSimpleProperty(bp);
if (resultBean == null) {
return false;
}
// try... | class class_name[name] begin[{]
method[hasIndexProperty, return_type[type[boolean]], modifier[protected], parameter[bp]] begin[{]
if[binary_operation[member[bp.bean], ==, literal[null]]] begin[{]
return[literal[false]]
else begin[{]
None
end[}]
local_variable... | Keyword[protected] Keyword[boolean] identifier[hasIndexProperty] operator[SEP] Keyword[final] identifier[BeanProperty] identifier[bp] operator[SEP] {
Keyword[if] operator[SEP] identifier[bp] operator[SEP] identifier[bean] operator[==] Other[null] operator[SEP] {
Keyword[return] literal[boolean] operat... |
public List<CmsResourceTypeBean> getPrecomputedTypes(CmsElementView view) {
return Lists.newArrayList(m_cachedTypes.get(view.getId()));
} | class class_name[name] begin[{]
method[getPrecomputedTypes, return_type[type[List]], modifier[public], parameter[view]] begin[{]
return[call[Lists.newArrayList, parameter[call[m_cachedTypes.get, parameter[call[view.getId, parameter[]]]]]]]
end[}]
END[}] | Keyword[public] identifier[List] operator[<] identifier[CmsResourceTypeBean] operator[>] identifier[getPrecomputedTypes] operator[SEP] identifier[CmsElementView] identifier[view] operator[SEP] {
Keyword[return] identifier[Lists] operator[SEP] identifier[newArrayList] operator[SEP] identifier[m_cachedTypes] opera... |
public <T> T readObject(final Object object, final DataTypeDescriptor<T> descriptor) {
try {
return objectFormat.read(object, descriptor);
} catch (Exception e) {
throw propagate(e);
}
} | class class_name[name] begin[{]
method[readObject, return_type[type[T]], modifier[public], parameter[object, descriptor]] begin[{]
TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[MemberReference(member=object, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[... | Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[readObject] operator[SEP] Keyword[final] identifier[Object] identifier[object] , Keyword[final] identifier[DataTypeDescriptor] operator[<] identifier[T] operator[>] identifier[descriptor] operator[SEP] {
Keyword[try] {
Key... |
public void afterThrowing(Method m, Object[] args, Object target, ConcurrencyFailureException e)
throws OptimisticLockingException {
handleOptimisticLockingException(target, e);
} | class class_name[name] begin[{]
method[afterThrowing, return_type[void], modifier[public], parameter[m, args, target, e]] begin[{]
call[.handleOptimisticLockingException, parameter[member[.target], member[.e]]]
end[}]
END[}] | Keyword[public] Keyword[void] identifier[afterThrowing] operator[SEP] identifier[Method] identifier[m] , identifier[Object] operator[SEP] operator[SEP] identifier[args] , identifier[Object] identifier[target] , identifier[ConcurrencyFailureException] identifier[e] operator[SEP] Keyword[throws] identifier[OptimisticL... |
public void buildAnnotationTypeRequiredMemberSummary(XMLNode node, Content memberSummaryTree) {
MemberSummaryWriter writer =
memberSummaryWriters[VisibleMemberMap.ANNOTATION_TYPE_MEMBER_REQUIRED];
VisibleMemberMap visibleMemberMap =
visibleMemberMaps[VisibleMemberMap.ANNO... | class class_name[name] begin[{]
method[buildAnnotationTypeRequiredMemberSummary, return_type[void], modifier[public], parameter[node, memberSummaryTree]] begin[{]
local_variable[type[MemberSummaryWriter], writer]
local_variable[type[VisibleMemberMap], visibleMemberMap]
call[.add... | Keyword[public] Keyword[void] identifier[buildAnnotationTypeRequiredMemberSummary] operator[SEP] identifier[XMLNode] identifier[node] , identifier[Content] identifier[memberSummaryTree] operator[SEP] {
identifier[MemberSummaryWriter] identifier[writer] operator[=] identifier[memberSummaryWriters] operator[SEP] ... |
private void fakeServiceCall() {
poller.enablePoll();
Cache.getCache().invalidate(DATA_KEY);
new Thread() {
@Override
public void run() {
try {
Thread.sleep(SERVICE_TIME);
Cache.getCache().put(DATA_KEY, "SUCCESS!");
} catch (InterruptedException e) {
LOG.error("Timed out calling serv... | class class_name[name] begin[{]
method[fakeServiceCall, return_type[void], modifier[private], parameter[]] begin[{]
call[poller.enablePoll, parameter[]]
call[Cache.getCache, parameter[]]
ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(e... | Keyword[private] Keyword[void] identifier[fakeServiceCall] operator[SEP] operator[SEP] {
identifier[poller] operator[SEP] identifier[enablePoll] operator[SEP] operator[SEP] operator[SEP] identifier[Cache] operator[SEP] identifier[getCache] operator[SEP] operator[SEP] operator[SEP] identifier[invalidate] operator... |
private void setConfiguration(SimpleJob job,
String[] labels,
String separator,
boolean formatIgnored,
boolean regex) {
Configuration conf = job.getConfiguration();
con... | class class_name[name] begin[{]
method[setConfiguration, return_type[void], modifier[private], parameter[job, labels, separator, formatIgnored, regex]] begin[{]
local_variable[type[Configuration], conf]
call[conf.setInt, parameter[member[SimpleJob.READER_TYPE], member[SimpleJob.SIMPLE_R... | Keyword[private] Keyword[void] identifier[setConfiguration] operator[SEP] identifier[SimpleJob] identifier[job] , identifier[String] operator[SEP] operator[SEP] identifier[labels] , identifier[String] identifier[separator] , Keyword[boolean] identifier[formatIgnored] , Keyword[boolean] identifier[regex] operator[SE... |
static void removeRegexes(List<IncomingPhoneNumber> numbers) {
//use a list to prevent conc access during iteration
List<IncomingPhoneNumber> toBeRemoved = new ArrayList();
if (numbers != null) {
for (IncomingPhoneNumber nAux : numbers) {
if (StringUtils.containsAny(n... | class class_name[name] begin[{]
method[removeRegexes, return_type[void], modifier[static], parameter[numbers]] begin[{]
local_variable[type[List], toBeRemoved]
if[binary_operation[member[.numbers], !=, literal[null]]] begin[{]
ForStatement(body=BlockStatement(label=None, sta... | Keyword[static] Keyword[void] identifier[removeRegexes] operator[SEP] identifier[List] operator[<] identifier[IncomingPhoneNumber] operator[>] identifier[numbers] operator[SEP] {
identifier[List] operator[<] identifier[IncomingPhoneNumber] operator[>] identifier[toBeRemoved] operator[=] Keyword[new] identifier[A... |
public DeploymentExtendedInner createOrUpdate(String resourceGroupName, String deploymentName, DeploymentProperties properties) {
return createOrUpdateWithServiceResponseAsync(resourceGroupName, deploymentName, properties).toBlocking().last().body();
} | class class_name[name] begin[{]
method[createOrUpdate, return_type[type[DeploymentExtendedInner]], modifier[public], parameter[resourceGroupName, deploymentName, properties]] begin[{]
return[call[.createOrUpdateWithServiceResponseAsync, parameter[member[.resourceGroupName], member[.deploymentName], mem... | Keyword[public] identifier[DeploymentExtendedInner] identifier[createOrUpdate] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[deploymentName] , identifier[DeploymentProperties] identifier[properties] operator[SEP] {
Keyword[return] identifier[createOrUpdateWithSe... |
public void postConstruct() {
parseGeometry();
Assert.isTrue(this.polygon != null, "Polygon is null. 'area' string is: '" + this.area + "'");
Assert.isTrue(this.display != null, "'display' is null");
Assert.isTrue(this.style == null || this.display == AoiDisplay.RENDER,
... | class class_name[name] begin[{]
method[postConstruct, return_type[void], modifier[public], parameter[]] begin[{]
call[.parseGeometry, parameter[]]
call[Assert.isTrue, parameter[binary_operation[THIS[member[None.polygon]], !=, literal[null]], binary_operation[binary_operation[lit... | Keyword[public] Keyword[void] identifier[postConstruct] operator[SEP] operator[SEP] {
identifier[parseGeometry] operator[SEP] operator[SEP] operator[SEP] identifier[Assert] operator[SEP] identifier[isTrue] operator[SEP] Keyword[this] operator[SEP] identifier[polygon] operator[!=] Other[null] , literal[String] o... |
void formatMinutes(StringBuilder b, ZonedDateTime d, int width) {
zeroPad2(b, d.getMinute(), width);
} | class class_name[name] begin[{]
method[formatMinutes, return_type[void], modifier[default], parameter[b, d, width]] begin[{]
call[.zeroPad2, parameter[member[.b], call[d.getMinute, parameter[]], member[.width]]]
end[}]
END[}] | Keyword[void] identifier[formatMinutes] operator[SEP] identifier[StringBuilder] identifier[b] , identifier[ZonedDateTime] identifier[d] , Keyword[int] identifier[width] operator[SEP] {
identifier[zeroPad2] operator[SEP] identifier[b] , identifier[d] operator[SEP] identifier[getMinute] operator[SEP] operator[S... |
private boolean fastForward() throws IOException {
try {
boolean stillTruncate;
buffer.clear();
if (channel.read(buffer) > -1 || isEof()) {
//set the buffer into read from mode
buffer.flip();
//we have data, lets look for the first EOL in it.
int firstEolIdx = findE... | class class_name[name] begin[{]
method[fastForward, return_type[type[boolean]], modifier[private], parameter[]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=None, name=stillTruncate)], modifiers=set(), type=BasicType(di... | Keyword[private] Keyword[boolean] identifier[fastForward] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[try] {
Keyword[boolean] identifier[stillTruncate] operator[SEP] identifier[buffer] operator[SEP] identifier[clear] operator[SEP] operator[SEP] operator[SEP] Keyword[i... |
private OnItemSelectedListener createItemSelectedListener() {
return new OnItemSelectedListener() {
@Override
public void onItemSelected(final AdapterView<?> parent, final View view,
final int position, final long id) {
if (getOnIte... | class class_name[name] begin[{]
method[createItemSelectedListener, return_type[type[OnItemSelectedListener]], modifier[private], parameter[]] begin[{]
return[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[IfStatement(condition=BinaryOpera... | Keyword[private] identifier[OnItemSelectedListener] identifier[createItemSelectedListener] operator[SEP] operator[SEP] {
Keyword[return] Keyword[new] identifier[OnItemSelectedListener] operator[SEP] operator[SEP] {
annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[onItemSelec... |
public final MappedByteBuffer load() {
checkMapped();
if ((address == 0) || (capacity() == 0))
return this;
long offset = mappingOffset();
long length = mappingLength(offset);
load0(mappingAddress(offset), length);
// Read a byte from each page to bring it in... | class class_name[name] begin[{]
method[load, return_type[type[MappedByteBuffer]], modifier[final public], parameter[]] begin[{]
call[.checkMapped, parameter[]]
if[binary_operation[binary_operation[member[.address], ==, literal[0]], ||, binary_operation[call[.capacity, parameter[... | Keyword[public] Keyword[final] identifier[MappedByteBuffer] identifier[load] operator[SEP] operator[SEP] {
identifier[checkMapped] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] operator[SEP] identifier[address] operator[==] Other[0] operator[SEP] operator[||] operator[SEP] identifier[capaci... |
protected void setClazzType(final Class<? extends TableEntity> clazzType) {
Utility.assertNotNull("clazzType", clazzType);
Utility.checkNullaryCtor(clazzType);
this.clazzType = clazzType;
} | class class_name[name] begin[{]
method[setClazzType, return_type[void], modifier[protected], parameter[clazzType]] begin[{]
call[Utility.assertNotNull, parameter[literal["clazzType"], member[.clazzType]]]
call[Utility.checkNullaryCtor, parameter[member[.clazzType]]]
... | Keyword[protected] Keyword[void] identifier[setClazzType] operator[SEP] Keyword[final] identifier[Class] operator[<] operator[?] Keyword[extends] identifier[TableEntity] operator[>] identifier[clazzType] operator[SEP] {
identifier[Utility] operator[SEP] identifier[assertNotNull] operator[SEP] literal[String] , ... |
public static void sigquitSelf() {
try {
Process p = Runtime.getRuntime().exec(
new String[] {"perl", "-e", "print getppid(). \"\n\";"});
BufferedReader br =
new BufferedReader(new InputStreamReader(p.getInputStream()));
String ppid = br.re... | class class_name[name] begin[{]
method[sigquitSelf, return_type[void], modifier[public static], parameter[]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arguments=[], member=getRuntime, postfix_operato... | Keyword[public] Keyword[static] Keyword[void] identifier[sigquitSelf] operator[SEP] operator[SEP] {
Keyword[try] {
identifier[Process] identifier[p] operator[=] identifier[Runtime] operator[SEP] identifier[getRuntime] operator[SEP] operator[SEP] operator[SEP] identifier[exec] operator[SEP] Keyword[new... |
public final void complete(T value) {
int state = get();
if ((state & (FUSED_READY | FUSED_CONSUMED | TERMINATED | DISPOSED)) != 0) {
return;
}
Observer<? super T> a = downstream;
if (state == FUSED_EMPTY) {
this.value = value;
lazySet(FUSED_RE... | class class_name[name] begin[{]
method[complete, return_type[void], modifier[final public], parameter[value]] begin[{]
local_variable[type[int], state]
if[binary_operation[binary_operation[member[.state], &, binary_operation[binary_operation[binary_operation[member[.FUSED_READY], |, mem... | Keyword[public] Keyword[final] Keyword[void] identifier[complete] operator[SEP] identifier[T] identifier[value] operator[SEP] {
Keyword[int] identifier[state] operator[=] identifier[get] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] operator[SEP] identifier[state] operator[&] operator[SEP] ... |
@SneakyThrows
public static byte[] signJws(final Key key, final byte[] value, final String algHeaderValue) {
val base64 = EncodingUtils.encodeBase64(value);
val jws = new JsonWebSignature();
jws.setEncodedPayload(base64);
jws.setAlgorithmHeaderValue(algHeaderValue);
jws.setKe... | class class_name[name] begin[{]
method[signJws, return_type[type[byte]], modifier[public static], parameter[key, value, algHeaderValue]] begin[{]
local_variable[type[val], base64]
local_variable[type[val], jws]
call[jws.setEncodedPayload, parameter[member[.base64]]]
... | annotation[@] identifier[SneakyThrows] Keyword[public] Keyword[static] Keyword[byte] operator[SEP] operator[SEP] identifier[signJws] operator[SEP] Keyword[final] identifier[Key] identifier[key] , Keyword[final] Keyword[byte] operator[SEP] operator[SEP] identifier[value] , Keyword[final] identifier[String] identifier[... |
@Override
public void openInfoStore() throws UnableToAdaptException {
try {
getInfoStore().open();
} catch (InfoStoreException e) {
String msg = Tr.formatMessage(tc, "failed.to.open.web.module.info.store.CWWKM0475E",
"Failed to open w... | class class_name[name] begin[{]
method[openInfoStore, return_type[void], modifier[public], parameter[]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[], member=getInfoStore, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[MethodInvocation(argu... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[openInfoStore] operator[SEP] operator[SEP] Keyword[throws] identifier[UnableToAdaptException] {
Keyword[try] {
identifier[getInfoStore] operator[SEP] operator[SEP] operator[SEP] identifier[open] operator[SEP] operator[SEP] ope... |
protected Variable getImportedVar(final String name) throws UtilEvalError {
Variable var = null;
// Try object imports
for (final Object object : this.importedObjects) {
final Invocable field = Reflect.resolveJavaField(object.getClass(),
name, false/* onlyStatic *... | class class_name[name] begin[{]
method[getImportedVar, return_type[type[Variable]], modifier[protected], parameter[name]] begin[{]
local_variable[type[Variable], var]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarato... | Keyword[protected] identifier[Variable] identifier[getImportedVar] operator[SEP] Keyword[final] identifier[String] identifier[name] operator[SEP] Keyword[throws] identifier[UtilEvalError] {
identifier[Variable] identifier[var] operator[=] Other[null] operator[SEP] Keyword[for] operator[SEP] Keyword[final] identi... |
public static <T> FluentFunctions.FluentFunction<T, T> checkedExpression(final CheckedConsumer<T> action) {
final Consumer<T> toUse = ExceptionSoftener.softenConsumer(action);
return FluentFunctions.of(t -> {
toUse.accept(t);
return t;
});
} | class class_name[name] begin[{]
method[checkedExpression, return_type[type[FluentFunctions]], modifier[public static], parameter[action]] begin[{]
local_variable[type[Consumer], toUse]
return[call[FluentFunctions.of, parameter[LambdaExpression(body=[StatementExpression(expression=MethodInvocati... | Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[FluentFunctions] operator[SEP] identifier[FluentFunction] operator[<] identifier[T] , identifier[T] operator[>] identifier[checkedExpression] operator[SEP] Keyword[final] identifier[CheckedConsumer] operator[<] identifier[T] operator[>] i... |
private void sawMethodOpcode(int seen) {
boolean isSyncCollection = false;
try {
stack.mergeJumps(this);
isSyncCollection = isSyncCollectionCreation(seen);
switch (seen) {
case Const.INVOKEVIRTUAL:
case Const.INVOKEINTERFACE:
... | class class_name[name] begin[{]
method[sawMethodOpcode, return_type[void], modifier[private], parameter[seen]] begin[{]
local_variable[type[boolean], isSyncCollection]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[This(postfix_operators=[], prefix_operators=[], ... | Keyword[private] Keyword[void] identifier[sawMethodOpcode] operator[SEP] Keyword[int] identifier[seen] operator[SEP] {
Keyword[boolean] identifier[isSyncCollection] operator[=] literal[boolean] operator[SEP] Keyword[try] {
identifier[stack] operator[SEP] identifier[mergeJumps] operator[SEP] Keyword[th... |
public static MariaDbConnection newConnection(UrlParser urlParser, GlobalStateInfo globalInfo)
throws SQLException {
if (urlParser.getOptions().pool) {
return Pools.retrievePool(urlParser).getConnection();
}
Protocol protocol = Utils.retrieveProxy(urlParser, globalInfo);
return new MariaDbC... | class class_name[name] begin[{]
method[newConnection, return_type[type[MariaDbConnection]], modifier[public static], parameter[urlParser, globalInfo]] begin[{]
if[call[urlParser.getOptions, parameter[]]] begin[{]
return[call[Pools.retrievePool, parameter[member[.urlParser]]]]
... | Keyword[public] Keyword[static] identifier[MariaDbConnection] identifier[newConnection] operator[SEP] identifier[UrlParser] identifier[urlParser] , identifier[GlobalStateInfo] identifier[globalInfo] operator[SEP] Keyword[throws] identifier[SQLException] {
Keyword[if] operator[SEP] identifier[urlParser] operator... |
public BillingAgreementRecipe getBrowserBillingAgreementConfig() {
for (BillingAgreementRecipe recipe : mBillingAgreementRecipesInDecreasingPriorityOrder) {
if (recipe.getTarget() == RequestTarget.browser) {
return recipe;
}
}
return null;
} | class class_name[name] begin[{]
method[getBrowserBillingAgreementConfig, return_type[type[BillingAgreementRecipe]], modifier[public], parameter[]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MethodInvocation(arguments=[], member=getTa... | Keyword[public] identifier[BillingAgreementRecipe] identifier[getBrowserBillingAgreementConfig] operator[SEP] operator[SEP] {
Keyword[for] operator[SEP] identifier[BillingAgreementRecipe] identifier[recipe] operator[:] identifier[mBillingAgreementRecipesInDecreasingPriorityOrder] operator[SEP] {
Keyw... |
private void initQueues()
{
LOGGER.debug("Init Queues");
if (_active.getAndSet(true))
{
// NOP if the loader is already active
return;
}
// start PUT and PROCESS queues
_queuePut = new ArrayBlockingQueue<>(48);
_queueProcess = new ArrayBlockingQueue<>(48);
_put = new PutQue... | class class_name[name] begin[{]
method[initQueues, return_type[void], modifier[private], parameter[]] begin[{]
call[LOGGER.debug, parameter[literal["Init Queues"]]]
if[call[_active.getAndSet, parameter[literal[true]]]] begin[{]
return[None]
else begin[{]
None... | Keyword[private] Keyword[void] identifier[initQueues] operator[SEP] operator[SEP] {
identifier[LOGGER] operator[SEP] identifier[debug] operator[SEP] literal[String] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[_active] operator[SEP] identifier[getAndSet] operator[SEP] literal[boolean] operato... |
public StringClauses insertBefore(String existingKey, String newValue) {
return insertBefore(existingKey, newValue, StringUtil.trimToNull(newValue));
} | class class_name[name] begin[{]
method[insertBefore, return_type[type[StringClauses]], modifier[public], parameter[existingKey, newValue]] begin[{]
return[call[.insertBefore, parameter[member[.existingKey], member[.newValue], call[StringUtil.trimToNull, parameter[member[.newValue]]]]]]
end[}]
END[}... | Keyword[public] identifier[StringClauses] identifier[insertBefore] operator[SEP] identifier[String] identifier[existingKey] , identifier[String] identifier[newValue] operator[SEP] {
Keyword[return] identifier[insertBefore] operator[SEP] identifier[existingKey] , identifier[newValue] , identifier[StringUtil] o... |
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{
int length = in.readInt();
this.remove = new ArrayList<String>(length);
for (int i = 0; i < length; i++)
{
remove.add(in.readUTF());
}
this.add = new LinkedList<Document>();
while ... | class class_name[name] begin[{]
method[readExternal, return_type[void], modifier[public], parameter[in]] begin[{]
local_variable[type[int], length]
assign[THIS[member[None.remove]], ClassCreator(arguments=[MemberReference(member=length, postfix_operators=[], prefix_operators=[], qualifi... | Keyword[public] Keyword[void] identifier[readExternal] operator[SEP] identifier[ObjectInput] identifier[in] operator[SEP] Keyword[throws] identifier[IOException] , identifier[ClassNotFoundException] {
Keyword[int] identifier[length] operator[=] identifier[in] operator[SEP] identifier[readInt] operator[SEP] oper... |
private void createQuickBox() {
if (hasQuickSearch() || hasQuickFilter()) {
m_quickSearch = new CmsTextBox();
// m_quickFilter.setVisible(hasQuickFilter());
m_quickSearch.addStyleName(DIALOG_CSS.quickFilterBox());
m_quickSearch.setTriggerChangeOnKeyPress(true);... | class class_name[name] begin[{]
method[createQuickBox, return_type[void], modifier[private], parameter[]] begin[{]
if[binary_operation[call[.hasQuickSearch, parameter[]], ||, call[.hasQuickFilter, parameter[]]]] begin[{]
assign[member[.m_quickSearch], ClassCreator(argume... | Keyword[private] Keyword[void] identifier[createQuickBox] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[hasQuickSearch] operator[SEP] operator[SEP] operator[||] identifier[hasQuickFilter] operator[SEP] operator[SEP] operator[SEP] {
identifier[m_quickSearch] operator[=] Keyword[new... |
private void initialize(@Nullable final AttributeSet attributeSet) {
constraints = new ArrayList<>();
helperTexts = new ArrayList<>();
helperTextColors = new ArrayList<>();
regularHelperText = getHelperText();
regularHelperTextColor = getHelperTextColor();
obtainStyledAtt... | class class_name[name] begin[{]
method[initialize, return_type[void], modifier[private], parameter[attributeSet]] begin[{]
assign[member[.constraints], ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[],... | Keyword[private] Keyword[void] identifier[initialize] operator[SEP] annotation[@] identifier[Nullable] Keyword[final] identifier[AttributeSet] identifier[attributeSet] operator[SEP] {
identifier[constraints] operator[=] Keyword[new] identifier[ArrayList] operator[<] operator[>] operator[SEP] operator[SEP] operat... |
public static org.jmxtrans.agent.util.json.JsonValue value(int value) {
return new org.jmxtrans.agent.util.json.JsonNumber(Integer.toString(value, 10));
} | class class_name[name] begin[{]
method[value, return_type[type[org]], modifier[public static], parameter[value]] begin[{]
return[ClassCreator(arguments=[MethodInvocation(arguments=[MemberReference(member=value, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), Literal(postfix_operat... | Keyword[public] Keyword[static] identifier[org] operator[SEP] identifier[jmxtrans] operator[SEP] identifier[agent] operator[SEP] identifier[util] operator[SEP] identifier[json] operator[SEP] identifier[JsonValue] identifier[value] operator[SEP] Keyword[int] identifier[value] operator[SEP] {
Keyword[return] Keywo... |
private void createActionStack() throws ParserException, GrammarException {
boolean accepted = false;
do {
checkTimeout();
stepCounter++;
if (logger.isTraceEnabled()) {
logger.trace(toString());
}
if (streamPosition > maxPosition) {
maxPosition = streamPosition;
}
final ParserAc... | class class_name[name] begin[{]
method[createActionStack, return_type[void], modifier[private], parameter[]] begin[{]
local_variable[type[boolean], accepted]
do[member[.accepted]] begin[{]
call[.checkTimeout, parameter[]]
member[.stepCount... | Keyword[private] Keyword[void] identifier[createActionStack] operator[SEP] operator[SEP] Keyword[throws] identifier[ParserException] , identifier[GrammarException] {
Keyword[boolean] identifier[accepted] operator[=] literal[boolean] operator[SEP] Keyword[do] {
identifier[checkTimeout] operator[SEP] o... |
private static void hideMultipleParts(IAtomContainer container, Sgroup sgroup) {
final Set<IBond> crossing = sgroup.getBonds();
final Set<IAtom> atoms = sgroup.getAtoms();
final Set<IAtom> parentAtoms = sgroup.getValue(SgroupKey.CtabParentAtomList);
for (IBond bond : container.bonds())... | class class_name[name] begin[{]
method[hideMultipleParts, return_type[void], modifier[private static], parameter[container, sgroup]] begin[{]
local_variable[type[Set], crossing]
local_variable[type[Set], atoms]
local_variable[type[Set], parentAtoms]
ForStatement(body=BlockStatem... | Keyword[private] Keyword[static] Keyword[void] identifier[hideMultipleParts] operator[SEP] identifier[IAtomContainer] identifier[container] , identifier[Sgroup] identifier[sgroup] operator[SEP] {
Keyword[final] identifier[Set] operator[<] identifier[IBond] operator[>] identifier[crossing] operator[=] identifier... |
protected void setComponentCursor (Component comp)
{
Cursor c = comp.getCursor();
if (c != _curCursor) {
assertComponentCursorCleared();
_lastComp = comp;
_oldCursor = comp.isCursorSet() ? c : null;
comp.setCursor(_curCursor);
}
} | class class_name[name] begin[{]
method[setComponentCursor, return_type[void], modifier[protected], parameter[comp]] begin[{]
local_variable[type[Cursor], c]
if[binary_operation[member[.c], !=, member[._curCursor]]] begin[{]
call[.assertComponentCursorCleared, par... | Keyword[protected] Keyword[void] identifier[setComponentCursor] operator[SEP] identifier[Component] identifier[comp] operator[SEP] {
identifier[Cursor] identifier[c] operator[=] identifier[comp] operator[SEP] identifier[getCursor] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[c] ... |
private static HystrixThreadPoolKey initThreadPoolKey(HystrixThreadPoolKey threadPoolKey, HystrixCommandGroupKey groupKey, String threadPoolKeyOverride) {
if (threadPoolKeyOverride == null) {
// we don't have a property overriding the value so use either HystrixThreadPoolKey or HystrixCommandGroup
... | class class_name[name] begin[{]
method[initThreadPoolKey, return_type[type[HystrixThreadPoolKey]], modifier[private static], parameter[threadPoolKey, groupKey, threadPoolKeyOverride]] begin[{]
if[binary_operation[member[.threadPoolKeyOverride], ==, literal[null]]] begin[{]
... | Keyword[private] Keyword[static] identifier[HystrixThreadPoolKey] identifier[initThreadPoolKey] operator[SEP] identifier[HystrixThreadPoolKey] identifier[threadPoolKey] , identifier[HystrixCommandGroupKey] identifier[groupKey] , identifier[String] identifier[threadPoolKeyOverride] operator[SEP] {
Keyword[if] o... |
@Override
public DescribeAvailabilityZonesResult describeAvailabilityZones(DescribeAvailabilityZonesRequest request) {
request = beforeClientExecution(request);
return executeDescribeAvailabilityZones(request);
} | class class_name[name] begin[{]
method[describeAvailabilityZones, return_type[type[DescribeAvailabilityZonesResult]], modifier[public], parameter[request]] begin[{]
assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]]
return[call[.executeDescribeAvailabili... | annotation[@] identifier[Override] Keyword[public] identifier[DescribeAvailabilityZonesResult] identifier[describeAvailabilityZones] operator[SEP] identifier[DescribeAvailabilityZonesRequest] identifier[request] operator[SEP] {
identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] ident... |
static protected Point2D newControl (Point2D start, Point2D ctrl, Point2D end) {
Point2D.Double newCtrl = new Point2D.Double();
newCtrl.x = 2 * ctrl.getX() - (start.getX() + end.getX()) / 2;
newCtrl.y = 2 * ctrl.getY() - (start.getY() + end.getY()) / 2;
return newCtrl;
} | class class_name[name] begin[{]
method[newControl, return_type[type[Point2D]], modifier[protected static], parameter[start, ctrl, end]] begin[{]
local_variable[type[Point2D], newCtrl]
assign[member[newCtrl.x], binary_operation[binary_operation[literal[2], *, call[ctrl.getX, parameter[]]... | Keyword[static] Keyword[protected] identifier[Point2D] identifier[newControl] operator[SEP] identifier[Point2D] identifier[start] , identifier[Point2D] identifier[ctrl] , identifier[Point2D] identifier[end] operator[SEP] {
identifier[Point2D] operator[SEP] identifier[Double] identifier[newCtrl] operator[=] Key... |
public MetadataManagerConfigurer localMetadataTrustedKeys(String... metadataTrustedKeys) {
localDelegate.metadataTrustedKeys = Arrays.stream(metadataTrustedKeys).collect(toSet());
return this;
} | class class_name[name] begin[{]
method[localMetadataTrustedKeys, return_type[type[MetadataManagerConfigurer]], modifier[public], parameter[metadataTrustedKeys]] begin[{]
assign[member[localDelegate.metadataTrustedKeys], call[Arrays.stream, parameter[member[.metadataTrustedKeys]]]]
retur... | Keyword[public] identifier[MetadataManagerConfigurer] identifier[localMetadataTrustedKeys] operator[SEP] identifier[String] operator[...] identifier[metadataTrustedKeys] operator[SEP] {
identifier[localDelegate] operator[SEP] identifier[metadataTrustedKeys] operator[=] identifier[Arrays] operator[SEP] identifier... |
private void fillMissingArtifactVersion(final ArtifactItem item) {
log.trace("Attempting to find missing version in {}:{}", item.getGroupId() , item.getArtifactId());
List list = project.getDependencies();
for (int i = 0; i < list.size(); ++i) {
Dependency dependency = (Dependency)... | class class_name[name] begin[{]
method[fillMissingArtifactVersion, return_type[void], modifier[private], parameter[item]] begin[{]
call[log.trace, parameter[literal["Attempting to find missing version in {}:{}"], call[item.getGroupId, parameter[]], call[item.getArtifactId, parameter[]]]]
... | Keyword[private] Keyword[void] identifier[fillMissingArtifactVersion] operator[SEP] Keyword[final] identifier[ArtifactItem] identifier[item] operator[SEP] {
identifier[log] operator[SEP] identifier[trace] operator[SEP] literal[String] , identifier[item] operator[SEP] identifier[getGroupId] operator[SEP] operato... |
@Override
public DMatrixRMaj getR(DMatrixRMaj R, boolean compact) {
if( compact ) {
R = UtilDecompositons_DDRM.checkZerosLT(R,minLength,numCols);
} else {
R = UtilDecompositons_DDRM.checkZerosLT(R,numRows,numCols);
}
for( int j = 0; j < numCols; j++ ) {
... | class class_name[name] begin[{]
method[getR, return_type[type[DMatrixRMaj]], modifier[public], parameter[R, compact]] begin[{]
if[member[.compact]] begin[{]
assign[member[.R], call[UtilDecompositons_DDRM.checkZerosLT, parameter[member[.R], member[.minLength], member[.num... | annotation[@] identifier[Override] Keyword[public] identifier[DMatrixRMaj] identifier[getR] operator[SEP] identifier[DMatrixRMaj] identifier[R] , Keyword[boolean] identifier[compact] operator[SEP] {
Keyword[if] operator[SEP] identifier[compact] operator[SEP] {
identifier[R] operator[=] identifier[Uti... |
public boolean setReadable(boolean readable, boolean ownerOnly) {
return doChmod(ownerOnly ? S_IRUSR : (S_IRUSR | S_IRGRP | S_IROTH), readable);
} | class class_name[name] begin[{]
method[setReadable, return_type[type[boolean]], modifier[public], parameter[readable, ownerOnly]] begin[{]
return[call[.doChmod, parameter[TernaryExpression(condition=MemberReference(member=ownerOnly, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), ... | Keyword[public] Keyword[boolean] identifier[setReadable] operator[SEP] Keyword[boolean] identifier[readable] , Keyword[boolean] identifier[ownerOnly] operator[SEP] {
Keyword[return] identifier[doChmod] operator[SEP] identifier[ownerOnly] operator[?] identifier[S_IRUSR] operator[:] operator[SEP] identifier[S_IR... |
void appendProperty( @Nonnull String name, @Nonnull Expression value ) {
if( output == null ) {
throw new LessException( "Properties must be inside selector blocks, they cannot be in the root." );
}
insets();
name = SelectorUtils.replacePlaceHolder( this, name, value );
... | class class_name[name] begin[{]
method[appendProperty, return_type[void], modifier[default], parameter[name, value]] begin[{]
if[binary_operation[member[.output], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_oper... | Keyword[void] identifier[appendProperty] operator[SEP] annotation[@] identifier[Nonnull] identifier[String] identifier[name] , annotation[@] identifier[Nonnull] identifier[Expression] identifier[value] operator[SEP] {
Keyword[if] operator[SEP] identifier[output] operator[==] Other[null] operator[SEP] {
... |
public void setDiffuse(float red, float green, float blue){
diffuse[0] = red;
diffuse[1] = green;
diffuse[2] = blue;
Di = true;
} | class class_name[name] begin[{]
method[setDiffuse, return_type[void], modifier[public], parameter[red, green, blue]] begin[{]
assign[member[.diffuse], member[.red]]
assign[member[.diffuse], member[.green]]
assign[member[.diffuse], member[.blue]]
a... | Keyword[public] Keyword[void] identifier[setDiffuse] operator[SEP] Keyword[float] identifier[red] , Keyword[float] identifier[green] , Keyword[float] identifier[blue] operator[SEP] {
identifier[diffuse] operator[SEP] Other[0] operator[SEP] operator[=] identifier[red] operator[SEP] identifier[diffuse] operator[... |
protected void writeMethodInfo(MethodInfo info) {
Node currentNode = this.currentNode;
Element tmp = doc.createElementNS(XML_URI, "method");
currentNode.appendChild(tmp);
this.currentNode = tmp;
addAccessFlags(info);
if (info.getName() != null)
tmp.setAttribu... | class class_name[name] begin[{]
method[writeMethodInfo, return_type[void], modifier[protected], parameter[info]] begin[{]
local_variable[type[Node], currentNode]
local_variable[type[Element], tmp]
call[currentNode.appendChild, parameter[member[.tmp]]]
assign[THIS... | Keyword[protected] Keyword[void] identifier[writeMethodInfo] operator[SEP] identifier[MethodInfo] identifier[info] operator[SEP] {
identifier[Node] identifier[currentNode] operator[=] Keyword[this] operator[SEP] identifier[currentNode] operator[SEP] identifier[Element] identifier[tmp] operator[=] identifier[doc]... |
@PostLoad
public void postLoad() {
if (principalAttributesRepository == null) {
this.principalAttributesRepository = new DefaultPrincipalAttributesRepository();
}
if (consentPolicy == null) {
this.consentPolicy = new DefaultRegisteredServiceConsentPolicy();
}
... | class class_name[name] begin[{]
method[postLoad, return_type[void], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.principalAttributesRepository], ==, literal[null]]] begin[{]
assign[THIS[member[None.principalAttributesRepository]], ClassCreator(argu... | annotation[@] identifier[PostLoad] Keyword[public] Keyword[void] identifier[postLoad] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[principalAttributesRepository] operator[==] Other[null] operator[SEP] {
Keyword[this] operator[SEP] identifier[principalAttributesRepository] operato... |
public static TextLoader getInstance(Encoding encoding)
{
if (null == encoding)
{
return getInstance();
}
else
{
if (!INSTANCE_BY_ENCODING.containsKey(encoding.getIsoName()))
{
TextLoader _newInstance = new TextLoader(encoding);
INSTANCE_BY_ENCODING.put(encoding.getIsoName(), _newInstance);
... | class class_name[name] begin[{]
method[getInstance, return_type[type[TextLoader]], modifier[public static], parameter[encoding]] begin[{]
if[binary_operation[literal[null], ==, member[.encoding]]] begin[{]
return[call[.getInstance, parameter[]]]
else begin[{]
... | Keyword[public] Keyword[static] identifier[TextLoader] identifier[getInstance] operator[SEP] identifier[Encoding] identifier[encoding] operator[SEP] {
Keyword[if] operator[SEP] Other[null] operator[==] identifier[encoding] operator[SEP] {
Keyword[return] identifier[getInstance] operator[SEP] operator[... |
public RelationTypeImpl buildRelationType(VertexElement vertex, RelationType type) {
return getOrBuildConcept(vertex, (v) -> RelationTypeImpl.create(v, type));
} | class class_name[name] begin[{]
method[buildRelationType, return_type[type[RelationTypeImpl]], modifier[public], parameter[vertex, type]] begin[{]
return[call[.getOrBuildConcept, parameter[member[.vertex], LambdaExpression(body=MethodInvocation(arguments=[MemberReference(member=v, postfix_operators=[],... | Keyword[public] identifier[RelationTypeImpl] identifier[buildRelationType] operator[SEP] identifier[VertexElement] identifier[vertex] , identifier[RelationType] identifier[type] operator[SEP] {
Keyword[return] identifier[getOrBuildConcept] operator[SEP] identifier[vertex] , operator[SEP] identifier[v] operator... |
private final int nextFromTree()
throws XMLStreamException
{
int i;
// First, do we need to finish currently open token?
if (mTokenState < mStTextThreshold) {
// No need to update state... will get taken care of
/* 03-Mar-2006, TSa: Let's add a sanity check h... | class class_name[name] begin[{]
method[nextFromTree, return_type[type[int]], modifier[final private], parameter[]] begin[{]
local_variable[type[int], i]
if[binary_operation[member[.mTokenState], <, member[.mStTextThreshold]]] begin[{]
if[binary_operation[member[.... | Keyword[private] Keyword[final] Keyword[int] identifier[nextFromTree] operator[SEP] operator[SEP] Keyword[throws] identifier[XMLStreamException] {
Keyword[int] identifier[i] operator[SEP] Keyword[if] operator[SEP] identifier[mTokenState] operator[<] identifier[mStTextThreshold] operator[SEP] {
Keyword... |
private String formatConstraintType(ConstraintType type)
{
return (type == null ? null : LocaleData.getStringArray(m_locale, LocaleData.CONSTRAINT_TYPES)[type.getValue()]);
} | class class_name[name] begin[{]
method[formatConstraintType, return_type[type[String]], modifier[private], parameter[type]] begin[{]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=type, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), operandr=Li... | Keyword[private] identifier[String] identifier[formatConstraintType] operator[SEP] identifier[ConstraintType] identifier[type] operator[SEP] {
Keyword[return] operator[SEP] identifier[type] operator[==] Other[null] operator[?] Other[null] operator[:] identifier[LocaleData] operator[SEP] identifier[getStringArra... |
private void checkSolaris(String PortName, int PortType) {
char p[] = {91};
for (p[0] = 97; p[0] < 123; p[0]++) {
if (testRead(PortName.concat(new String(p)), PortType)) {
CommPortIdentifier.addPortName(PortName.concat(new String(p)), PortType, this);
}
}
... | class class_name[name] begin[{]
method[checkSolaris, return_type[void], modifier[private], parameter[PortName, PortType]] begin[{]
local_variable[type[char], p]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MethodInvocation(arguments=... | Keyword[private] Keyword[void] identifier[checkSolaris] operator[SEP] identifier[String] identifier[PortName] , Keyword[int] identifier[PortType] operator[SEP] {
Keyword[char] identifier[p] operator[SEP] operator[SEP] operator[=] {
Other[91]
} operator[SEP] Keyword[for] operator[SEP] identifie... |
private static void handleEqualityComparison(
boolean equalTo,
Node leftNode,
Node rightNode,
SubNodeValues inputs,
Updates thenUpdates,
Updates elseUpdates) {
Nullness leftVal = inputs.valueOfSubNode(leftNode);
Nullness rightVal = inputs.valueOfSubNode(rightNode);
Nullne... | class class_name[name] begin[{]
method[handleEqualityComparison, return_type[void], modifier[private static], parameter[equalTo, leftNode, rightNode, inputs, thenUpdates, elseUpdates]] begin[{]
local_variable[type[Nullness], leftVal]
local_variable[type[Nullness], rightVal]
local_variab... | Keyword[private] Keyword[static] Keyword[void] identifier[handleEqualityComparison] operator[SEP] Keyword[boolean] identifier[equalTo] , identifier[Node] identifier[leftNode] , identifier[Node] identifier[rightNode] , identifier[SubNodeValues] identifier[inputs] , identifier[Updates] identifier[thenUpdates] , iden... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.