code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
public Matrix4x3d rotateYXZ(Vector3d angles) {
return rotateYXZ(angles.y, angles.x, angles.z);
} | class class_name[name] begin[{]
method[rotateYXZ, return_type[type[Matrix4x3d]], modifier[public], parameter[angles]] begin[{]
return[call[.rotateYXZ, parameter[member[angles.y], member[angles.x], member[angles.z]]]]
end[}]
END[}] | Keyword[public] identifier[Matrix4x3d] identifier[rotateYXZ] operator[SEP] identifier[Vector3d] identifier[angles] operator[SEP] {
Keyword[return] identifier[rotateYXZ] operator[SEP] identifier[angles] operator[SEP] identifier[y] , identifier[angles] operator[SEP] identifier[x] , identifier[angles] operator[SE... |
protected String findValidHeaderValue(Set<CharSequence> paramValues) {
String selectedValue = null;
if (paramValues != null && !paramValues.isEmpty()) {
CharSequence value = paramValues.iterator().next();
if (!(value instanceof QueryParameterValue)) {
selectedValue = value.toString();
... | class class_name[name] begin[{]
method[findValidHeaderValue, return_type[type[String]], modifier[protected], parameter[paramValues]] begin[{]
local_variable[type[String], selectedValue]
if[binary_operation[binary_operation[member[.paramValues], !=, literal[null]], &&, call[paramValues.i... | Keyword[protected] identifier[String] identifier[findValidHeaderValue] operator[SEP] identifier[Set] operator[<] identifier[CharSequence] operator[>] identifier[paramValues] operator[SEP] {
identifier[String] identifier[selectedValue] operator[=] Other[null] operator[SEP] Keyword[if] operator[SEP] identifier[par... |
public static <M> Subscription destroyOnClose(final Window window, final AbstractViewController<M> viewBinder) {
Assert.requireNonNull(window, "window");
Assert.requireNonNull(viewBinder, "viewBinder");
final EventHandler<WindowEvent> handler = e -> viewBinder.destroy();
window.addEventF... | class class_name[name] begin[{]
method[destroyOnClose, return_type[type[Subscription]], modifier[public static], parameter[window, viewBinder]] begin[{]
call[Assert.requireNonNull, parameter[member[.window], literal["window"]]]
call[Assert.requireNonNull, parameter[member[.viewB... | Keyword[public] Keyword[static] operator[<] identifier[M] operator[>] identifier[Subscription] identifier[destroyOnClose] operator[SEP] Keyword[final] identifier[Window] identifier[window] , Keyword[final] identifier[AbstractViewController] operator[<] identifier[M] operator[>] identifier[viewBinder] operator[SEP] {
... |
public static boolean matches(String pattern, String value) {
Pattern p = Pattern.compile(pattern);
Matcher m = p.matcher(value);
return m.matches();
} | class class_name[name] begin[{]
method[matches, return_type[type[boolean]], modifier[public static], parameter[pattern, value]] begin[{]
local_variable[type[Pattern], p]
local_variable[type[Matcher], m]
return[call[m.matches, parameter[]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[boolean] identifier[matches] operator[SEP] identifier[String] identifier[pattern] , identifier[String] identifier[value] operator[SEP] {
identifier[Pattern] identifier[p] operator[=] identifier[Pattern] operator[SEP] identifier[compile] operator[SEP] identifier[pattern] o... |
public S3URI getParent() {
if (key == null) {
return null;
}
int lastDelimPos = key.lastIndexOf(S3_DELIMITER);
if (lastDelimPos == -1) {
return new S3URI(bucket, null);
} else {
return new S3URI(bucket, key.substring(0, lastDelimPos));
... | class class_name[name] begin[{]
method[getParent, return_type[type[S3URI]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.key], ==, literal[null]]] begin[{]
return[literal[null]]
else begin[{]
None
end[}]
local_variable[type[int], lastDe... | Keyword[public] identifier[S3URI] identifier[getParent] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[key] operator[==] Other[null] operator[SEP] {
Keyword[return] Other[null] operator[SEP]
}
Keyword[int] identifier[lastDelimPos] operator[=] identifier[key] operator[... |
public Object getJsonPath(String json, String jsonPath) {
if (!JsonPath.isPathDefinite(jsonPath)) {
throw new RuntimeException(jsonPath + " returns a list of results, not a single.");
}
return parseJson(json).read(jsonPath);
} | class class_name[name] begin[{]
method[getJsonPath, return_type[type[Object]], modifier[public], parameter[json, jsonPath]] begin[{]
if[call[JsonPath.isPathDefinite, parameter[member[.jsonPath]]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[BinaryOperation(operandl=Me... | Keyword[public] identifier[Object] identifier[getJsonPath] operator[SEP] identifier[String] identifier[json] , identifier[String] identifier[jsonPath] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[JsonPath] operator[SEP] identifier[isPathDefinite] operator[SEP] identifier[jsonPath] operator[S... |
private static Object checkComponentType(Object array, Class<?> expectedComponentType) {
Class<?> actualComponentType = array.getClass().getComponentType();
if (!expectedComponentType.isAssignableFrom(actualComponentType)) {
throw new ArrayStoreException(
String.format("The expected component type %s is not... | class class_name[name] begin[{]
method[checkComponentType, return_type[type[Object]], modifier[private static], parameter[array, expectedComponentType]] begin[{]
local_variable[type[Class], actualComponentType]
if[call[expectedComponentType.isAssignableFrom, parameter[member[.actualComp... | Keyword[private] Keyword[static] identifier[Object] identifier[checkComponentType] operator[SEP] identifier[Object] identifier[array] , identifier[Class] operator[<] operator[?] operator[>] identifier[expectedComponentType] operator[SEP] {
identifier[Class] operator[<] operator[?] operator[>] identifier[actualC... |
public Enumeration<String> getElements() {
AttributeNameEnumeration elements = new AttributeNameEnumeration();
elements.addElement(SKIP_CERTS);
return (elements.elements());
} | class class_name[name] begin[{]
method[getElements, return_type[type[Enumeration]], modifier[public], parameter[]] begin[{]
local_variable[type[AttributeNameEnumeration], elements]
call[elements.addElement, parameter[member[.SKIP_CERTS]]]
return[call[elements.elements, parameter... | Keyword[public] identifier[Enumeration] operator[<] identifier[String] operator[>] identifier[getElements] operator[SEP] operator[SEP] {
identifier[AttributeNameEnumeration] identifier[elements] operator[=] Keyword[new] identifier[AttributeNameEnumeration] operator[SEP] operator[SEP] operator[SEP] identifier[ele... |
private void setUpgradeRequestHeaders(ChannelHandlerContext ctx, HttpRequest request) {
// Set the UPGRADE header on the request.
request.headers().set(HttpHeaderNames.UPGRADE, upgradeCodec.protocol());
// Add all protocol-specific headers to the request.
Set<CharSequence> connectionPar... | class class_name[name] begin[{]
method[setUpgradeRequestHeaders, return_type[void], modifier[private], parameter[ctx, request]] begin[{]
call[request.headers, parameter[]]
local_variable[type[Set], connectionParts]
call[connectionParts.addAll, parameter[call[upgradeCodec... | Keyword[private] Keyword[void] identifier[setUpgradeRequestHeaders] operator[SEP] identifier[ChannelHandlerContext] identifier[ctx] , identifier[HttpRequest] identifier[request] operator[SEP] {
identifier[request] operator[SEP] identifier[headers] operator[SEP] operator[SEP] operator[SEP] identifier[set] operat... |
public void deleteMergeRequestAwardEmoji(Object projectIdOrPath, Integer mergeRequestIid, Integer awardId) throws GitLabApiException {
delete(Response.Status.NO_CONTENT, null,
"projects", getProjectIdOrPath(projectIdOrPath), "merge_requests", mergeRequestIid, "award_emoji", awardId);
} | class class_name[name] begin[{]
method[deleteMergeRequestAwardEmoji, return_type[void], modifier[public], parameter[projectIdOrPath, mergeRequestIid, awardId]] begin[{]
call[.delete, parameter[member[Response.Status.NO_CONTENT], literal[null], literal["projects"], call[.getProjectIdOrPath, para... | Keyword[public] Keyword[void] identifier[deleteMergeRequestAwardEmoji] operator[SEP] identifier[Object] identifier[projectIdOrPath] , identifier[Integer] identifier[mergeRequestIid] , identifier[Integer] identifier[awardId] operator[SEP] Keyword[throws] identifier[GitLabApiException] {
identifier[delete] opera... |
public static Catalog crawlDatabase(final Connection connection, final InclusionRule schemaRule, final InclusionRule tableRule) throws SchemaCrawlerException {
final SchemaCrawlerOptions options = SchemaCrawlerOptionsBuilder.builder()
.withSchemaInfoLevel(SchemaInfoLevelBuilder.standard().setR... | class class_name[name] begin[{]
method[crawlDatabase, return_type[type[Catalog]], modifier[public static], parameter[connection, schemaRule, tableRule]] begin[{]
local_variable[type[SchemaCrawlerOptions], options]
TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[Member... | Keyword[public] Keyword[static] identifier[Catalog] identifier[crawlDatabase] operator[SEP] Keyword[final] identifier[Connection] identifier[connection] , Keyword[final] identifier[InclusionRule] identifier[schemaRule] , Keyword[final] identifier[InclusionRule] identifier[tableRule] operator[SEP] Keyword[throws] iden... |
@Override
public void configureConstraintWeight(Rule rule, BendableScore constraintWeight) {
super.configureConstraintWeight(rule, constraintWeight);
BiConsumer<RuleContext, Integer> matchExecutor;
if (constraintWeight.equals(BendableScore.zero(hardScores.length, softScores.length))) {
... | class class_name[name] begin[{]
method[configureConstraintWeight, return_type[void], modifier[public], parameter[rule, constraintWeight]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=rule, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberReference(... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[configureConstraintWeight] operator[SEP] identifier[Rule] identifier[rule] , identifier[BendableScore] identifier[constraintWeight] operator[SEP] {
Keyword[super] operator[SEP] identifier[configureConstraintWeight] operator[SEP] identif... |
public void setEnabled(boolean enabled) {
super.setEnabled(enabled);
for (Iterator members = getMemberList().iterator(); members.hasNext();)
{
GroupMember groupMember = (GroupMember)members.next();
groupMember.setEnabled(enabled);
}
} | class class_name[name] begin[{]
method[setEnabled, return_type[void], modifier[public], parameter[enabled]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=enabled, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], member=setEnabled, postfix_operators=[], p... | Keyword[public] Keyword[void] identifier[setEnabled] operator[SEP] Keyword[boolean] identifier[enabled] operator[SEP] {
Keyword[super] operator[SEP] identifier[setEnabled] operator[SEP] identifier[enabled] operator[SEP] operator[SEP] Keyword[for] operator[SEP] identifier[Iterator] identifier[members] operator[=]... |
public int getFieldSeq(String fieldName)
{
for (int i = 0; i < this.getFieldCount(); i++)
{
if (fieldName.equals(this.getField(i).getFieldName()))
return i;
}
return -1;
} | class class_name[name] begin[{]
method[getFieldSeq, return_type[type[int]], modifier[public], parameter[fieldName]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[This(postfix_operators=[], prefix_operators=[], qualifier=None, selecto... | Keyword[public] Keyword[int] identifier[getFieldSeq] operator[SEP] identifier[String] identifier[fieldName] operator[SEP] {
Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] operator[SEP] identifier[i] operator[<] Keyword[this] operator[SEP] identifier[getFieldCount] operator[SEP] operat... |
private boolean createPageAnchor(ServletRequest req, TagRenderingBase trb)
{
// create the fragment identifier. If the _linkName starts with
// '#' then we treat it as if it was fully qualified. Otherwise we
// need to qualify it before we add the '#'.
_linkName = _linkName.trim();... | class class_name[name] begin[{]
method[createPageAnchor, return_type[type[boolean]], modifier[private], parameter[req, trb]] begin[{]
assign[member[._linkName], call[_linkName.trim, parameter[]]]
if[binary_operation[call[_linkName.charAt, parameter[literal[0]]], !=, literal['#']... | Keyword[private] Keyword[boolean] identifier[createPageAnchor] operator[SEP] identifier[ServletRequest] identifier[req] , identifier[TagRenderingBase] identifier[trb] operator[SEP] {
identifier[_linkName] operator[=] identifier[_linkName] operator[SEP] identifier[trim] operator[SEP] operator[SEP] operator[SEP] ... |
public static BEValue bdecode(ByteBuffer data) throws IOException {
return BDecoder.bdecode(new ByteArrayInputStream(data.array()));
} | class class_name[name] begin[{]
method[bdecode, return_type[type[BEValue]], modifier[public static], parameter[data]] begin[{]
return[call[BDecoder.bdecode, parameter[ClassCreator(arguments=[MethodInvocation(arguments=[], member=array, postfix_operators=[], prefix_operators=[], qualifier=data, selector... | Keyword[public] Keyword[static] identifier[BEValue] identifier[bdecode] operator[SEP] identifier[ByteBuffer] identifier[data] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[return] identifier[BDecoder] operator[SEP] identifier[bdecode] operator[SEP] Keyword[new] identifier[ByteArrayInputStream] ... |
private SimpleRelation buildSimpleManyToOneOneToVirtualOne(Entity entity, final Attribute fromAttribute, Entity targetEntity, Attribute targetAttribute) {
Namer targetNamer = relationUtil.getManyToOneNamer(fromAttribute, targetEntity.getModel());
Namer inverseNamer = relationUtil.getOneToManyNamer(fromA... | class class_name[name] begin[{]
method[buildSimpleManyToOneOneToVirtualOne, return_type[type[SimpleRelation]], modifier[private], parameter[entity, fromAttribute, targetEntity, targetAttribute]] begin[{]
local_variable[type[Namer], targetNamer]
local_variable[type[Namer], inverseNamer]
... | Keyword[private] identifier[SimpleRelation] identifier[buildSimpleManyToOneOneToVirtualOne] operator[SEP] identifier[Entity] identifier[entity] , Keyword[final] identifier[Attribute] identifier[fromAttribute] , identifier[Entity] identifier[targetEntity] , identifier[Attribute] identifier[targetAttribute] operator[S... |
public String getRealPath(final String path) {
if (path == null) return null;
if (isContextPathSet && path.startsWith(contextPath)) return webappPath + path.substring(contextPath.length());
return webappPath + path;
} | class class_name[name] begin[{]
method[getRealPath, return_type[type[String]], modifier[public], parameter[path]] begin[{]
if[binary_operation[member[.path], ==, literal[null]]] begin[{]
return[literal[null]]
else begin[{]
None
end[}]
if[binary_operation[member[.... | Keyword[public] identifier[String] identifier[getRealPath] operator[SEP] Keyword[final] identifier[String] identifier[path] operator[SEP] {
Keyword[if] operator[SEP] identifier[path] operator[==] Other[null] operator[SEP] Keyword[return] Other[null] operator[SEP] Keyword[if] operator[SEP] identifier[isContextPat... |
public Iterable<ListBlobItem> listLogBlobs(StorageService service) throws URISyntaxException, StorageException {
return this.listLogBlobs(service, null /* startTime */, null /* endTime */, null /* operations */,
null /* details */, null /* options */, null /* operationContext */);
} | class class_name[name] begin[{]
method[listLogBlobs, return_type[type[Iterable]], modifier[public], parameter[service]] begin[{]
return[THIS[call[None.listLogBlobs, parameter[member[.service], literal[null], literal[null], literal[null], literal[null], literal[null], literal[null]]]]]
end[}]
END[}] | Keyword[public] identifier[Iterable] operator[<] identifier[ListBlobItem] operator[>] identifier[listLogBlobs] operator[SEP] identifier[StorageService] identifier[service] operator[SEP] Keyword[throws] identifier[URISyntaxException] , identifier[StorageException] {
Keyword[return] Keyword[this] operator[SEP] id... |
@Override
public void parseHeader(String header, S sequence) {
sequence.setOriginalHeader(header);
sequence.setAccession(new AccessionID(accession, DataSource.GENBANK, version, identifier));
sequence.setDescription(description);
sequence.setComments(comments);
sequence.setReferences(references);
} | class class_name[name] begin[{]
method[parseHeader, return_type[void], modifier[public], parameter[header, sequence]] begin[{]
call[sequence.setOriginalHeader, parameter[member[.header]]]
call[sequence.setAccession, parameter[ClassCreator(arguments=[MemberReference(member=access... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[parseHeader] operator[SEP] identifier[String] identifier[header] , identifier[S] identifier[sequence] operator[SEP] {
identifier[sequence] operator[SEP] identifier[setOriginalHeader] operator[SEP] identifier[header] operator[SEP] operat... |
private void requirePending() {
if (pending != null) {
return;
}
long exclusionComparable = Long.MIN_VALUE;
while (nInclusionsRemaining != 0 && !queue.isEmpty()) {
//find a candidate that is not excluded
HeapElement inclusion = null;
do {
HeapElement candidate = queue.poll();
if (candidate.... | class class_name[name] begin[{]
method[requirePending, return_type[void], modifier[private], parameter[]] begin[{]
if[binary_operation[member[.pending], !=, literal[null]]] begin[{]
return[None]
else begin[{]
None
end[}]
local_variable[type[long], exclusionCo... | Keyword[private] Keyword[void] identifier[requirePending] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[pending] operator[!=] Other[null] operator[SEP] {
Keyword[return] operator[SEP]
}
Keyword[long] identifier[exclusionComparable] operator[=] identifier[Long] operat... |
public static Function<? super ReactiveSeq<Integer>, ? extends ReactiveSeq<Integer>> concatInts( ReactiveSeq<Integer> b){
return a->ReactiveSeq.fromSpliterator(IntStream.concat(a.mapToInt(i->i),b.mapToInt(i->i)).spliterator());
} | class class_name[name] begin[{]
method[concatInts, return_type[type[Function]], modifier[public static], parameter[b]] begin[{]
return[LambdaExpression(body=MethodInvocation(arguments=[MethodInvocation(arguments=[MethodInvocation(arguments=[LambdaExpression(body=MemberReference(member=i, postfix_operat... | Keyword[public] Keyword[static] identifier[Function] operator[<] operator[?] Keyword[super] identifier[ReactiveSeq] operator[<] identifier[Integer] operator[>] , operator[?] Keyword[extends] identifier[ReactiveSeq] operator[<] identifier[Integer] operator[>] operator[>] identifier[concatInts] operator[SEP] identifier[... |
public static Result badRequest(JsonNode content, JsonEncoding encoding) {
return status(BAD_REQUEST, content, encoding);
} | class class_name[name] begin[{]
method[badRequest, return_type[type[Result]], modifier[public static], parameter[content, encoding]] begin[{]
return[call[.status, parameter[member[.BAD_REQUEST], member[.content], member[.encoding]]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[Result] identifier[badRequest] operator[SEP] identifier[JsonNode] identifier[content] , identifier[JsonEncoding] identifier[encoding] operator[SEP] {
Keyword[return] identifier[status] operator[SEP] identifier[BAD_REQUEST] , identifier[content] , identifier[encoding]... |
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case AfplibPackage.EDI__INDX_NAME:
return getIndxName();
case AfplibPackage.EDI__TRIPLETS:
return getTriplets();
}
return super.eGet(featureID, resolve, coreType);
} | class class_name[name] begin[{]
method[eGet, return_type[type[Object]], modifier[public], parameter[featureID, resolve, coreType]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=[MemberReference(member=EDI__INDX_NAME, postfix_operators=[], prefix_operators=[], qualifier=AfplibPackage, selecto... | 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... |
private static boolean isKnownLeafClassLoader(final ClassLoader classLoader) {
if (classLoader == null) {
return false;
}
if (!isKnownClassLoaderAccessibleFrom(classClassLoader, classLoader)) {
// We cannot access the class class loader from the specified class loader, ... | class class_name[name] begin[{]
method[isKnownLeafClassLoader, return_type[type[boolean]], modifier[private static], parameter[classLoader]] begin[{]
if[binary_operation[member[.classLoader], ==, literal[null]]] begin[{]
return[literal[false]]
else begin[{]
None
end[... | Keyword[private] Keyword[static] Keyword[boolean] identifier[isKnownLeafClassLoader] operator[SEP] Keyword[final] identifier[ClassLoader] identifier[classLoader] operator[SEP] {
Keyword[if] operator[SEP] identifier[classLoader] operator[==] Other[null] operator[SEP] {
Keyword[return] literal[boolean] ... |
public ResourcePendingMaintenanceActions withPendingMaintenanceActionDetails(PendingMaintenanceAction... pendingMaintenanceActionDetails) {
if (this.pendingMaintenanceActionDetails == null) {
setPendingMaintenanceActionDetails(new java.util.ArrayList<PendingMaintenanceAction>(pendingMaintenanceActio... | class class_name[name] begin[{]
method[withPendingMaintenanceActionDetails, return_type[type[ResourcePendingMaintenanceActions]], modifier[public], parameter[pendingMaintenanceActionDetails]] begin[{]
if[binary_operation[THIS[member[None.pendingMaintenanceActionDetails]], ==, literal[null]]] be... | Keyword[public] identifier[ResourcePendingMaintenanceActions] identifier[withPendingMaintenanceActionDetails] operator[SEP] identifier[PendingMaintenanceAction] operator[...] identifier[pendingMaintenanceActionDetails] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[pendingMainte... |
public static double median (double[] vector) {
final double[] sorted = vector.clone();
Arrays.sort(sorted);
if (vector.length % 2 == 1) {
return sorted[vector.length / 2];
}
return (sorted[vector.length / 2 - 1] + sorted[vector.length / 2]) / 2;
} | class class_name[name] begin[{]
method[median, return_type[type[double]], modifier[public static], parameter[vector]] begin[{]
local_variable[type[double], sorted]
call[Arrays.sort, parameter[member[.sorted]]]
if[binary_operation[binary_operation[member[vector.length], %... | Keyword[public] Keyword[static] Keyword[double] identifier[median] operator[SEP] Keyword[double] operator[SEP] operator[SEP] identifier[vector] operator[SEP] {
Keyword[final] Keyword[double] operator[SEP] operator[SEP] identifier[sorted] operator[=] identifier[vector] operator[SEP] identifier[clone] operator[SEP... |
public static File getJavaTools() throws MalformedURLException {
File javaToolsFile = null;
String javaHome = System.getProperty("java.home");
//if the tools.jar can't be found under the java home, then goto java home's parent and try again.
//this case would happen when user set the jr... | class class_name[name] begin[{]
method[getJavaTools, return_type[type[File]], modifier[public static], parameter[]] begin[{]
local_variable[type[File], javaToolsFile]
local_variable[type[String], javaHome]
if[binary_operation[binary_operation[literal[null], !=, member[.javaHome]... | Keyword[public] Keyword[static] identifier[File] identifier[getJavaTools] operator[SEP] operator[SEP] Keyword[throws] identifier[MalformedURLException] {
identifier[File] identifier[javaToolsFile] operator[=] Other[null] operator[SEP] identifier[String] identifier[javaHome] operator[=] identifier[System] operato... |
public void activate(ComponentContext compcontext) {
if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
Tr.debug(tc, "Activating " + this.getClass().getName());
}
INSTANCE.set(this);
} | class class_name[name] begin[{]
method[activate, return_type[void], modifier[public], parameter[compcontext]] begin[{]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isDebugEnabled, parameter[]]]] begin[{]
call[Tr.debug, parameter[... | Keyword[public] Keyword[void] identifier[activate] operator[SEP] identifier[ComponentContext] identifier[compcontext] operator[SEP] {
Keyword[if] operator[SEP] identifier[TraceComponent] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] operator[&&] identifier[tc] operator[SEP] identifier... |
public void processDocument(BufferedReader document) throws IOException {
// Iterate over all of the parseable dependency parsed sentences in the
// document.
for (DependencyTreeNode[] nodes = null;
(nodes = extractor.readNextTree(document)) != null; ) {
/... | class class_name[name] begin[{]
method[processDocument, return_type[void], modifier[public], parameter[document]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=length, postfix_operators=[], prefix_operators=[], qu... | Keyword[public] Keyword[void] identifier[processDocument] operator[SEP] identifier[BufferedReader] identifier[document] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[for] operator[SEP] identifier[DependencyTreeNode] operator[SEP] operator[SEP] identifier[nodes] operator[=] Other[null] operator[... |
public static final <T> Function<T,List<T>> intoSingletonListOf(final Type<T> type) {
return new IntoSingletonList<T>();
} | class class_name[name] begin[{]
method[intoSingletonListOf, return_type[type[Function]], modifier[final public static], parameter[type]] begin[{]
return[ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], type=R... | Keyword[public] Keyword[static] Keyword[final] operator[<] identifier[T] operator[>] identifier[Function] operator[<] identifier[T] , identifier[List] operator[<] identifier[T] operator[>] operator[>] identifier[intoSingletonListOf] operator[SEP] Keyword[final] identifier[Type] operator[<] identifier[T] operator[>] id... |
static Integer parseTimeConstraint(Instance instance, String constraint,
ConnectionManager cm) throws KnowledgeSourceReadException {
Integer constraintValue = null;
if (instance != null && constraint != null) {
constraintValue = (Integer) cm.getOwnSlotValue(instance,
... | class class_name[name] begin[{]
method[parseTimeConstraint, return_type[type[Integer]], modifier[static], parameter[instance, constraint, cm]] begin[{]
local_variable[type[Integer], constraintValue]
if[binary_operation[binary_operation[member[.instance], !=, literal[null]], &&, binary_o... | Keyword[static] identifier[Integer] identifier[parseTimeConstraint] operator[SEP] identifier[Instance] identifier[instance] , identifier[String] identifier[constraint] , identifier[ConnectionManager] identifier[cm] operator[SEP] Keyword[throws] identifier[KnowledgeSourceReadException] {
identifier[Integer] ide... |
private ByteArrayInputStream generateThumbImageByPercent(InputStream inputStream,
ThumbImage thumbImage) throws IOException {
LOGGER.debug("根据传入比例生成缩略图");
// 在内存当中生成缩略图
ByteArrayOutputStream out = new ByteArrayOutputStream();
/... | class class_name[name] begin[{]
method[generateThumbImageByPercent, return_type[type[ByteArrayInputStream]], modifier[private], parameter[inputStream, thumbImage]] begin[{]
call[LOGGER.debug, parameter[literal["根据传入比例生成缩略图"]]]
local_variable[type[ByteArrayOutputStream], out]
... | Keyword[private] identifier[ByteArrayInputStream] identifier[generateThumbImageByPercent] operator[SEP] identifier[InputStream] identifier[inputStream] , identifier[ThumbImage] identifier[thumbImage] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[LOGGER] operator[SEP] identifier[debug] opera... |
private void parseBodyMultipart() {
if (undecodedChunk == null || undecodedChunk.readableBytes() == 0) {
// nothing to decode
return;
}
InterfaceHttpData data = decodeMultipart(currentStatus);
while (data != null) {
addHttpData(data);
if (c... | class class_name[name] begin[{]
method[parseBodyMultipart, return_type[void], modifier[private], parameter[]] begin[{]
if[binary_operation[binary_operation[member[.undecodedChunk], ==, literal[null]], ||, binary_operation[call[undecodedChunk.readableBytes, parameter[]], ==, literal[0]]]] begin[... | Keyword[private] Keyword[void] identifier[parseBodyMultipart] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[undecodedChunk] operator[==] Other[null] operator[||] identifier[undecodedChunk] operator[SEP] identifier[readableBytes] operator[SEP] operator[SEP] operator[==] Other[0] operator[SEP]... |
@SuppressWarnings("unchecked")
public <T> T proxy(final Object delegate, Class<?> [] interfaces)
{
return (T)Proxy.newProxyInstance
(delegate.getClass().getClassLoader(),
interfaces,
new ProxyInvocationHandler(delegate));
} | class class_name[name] begin[{]
method[proxy, return_type[type[T]], modifier[public], parameter[delegate, interfaces]] begin[{]
return[Cast(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=getClass, postfix_operators=[], prefix_operators=[], qualifier=delegate, selectors=[Me... | annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[proxy] operator[SEP] Keyword[final] identifier[Object] identifier[delegate] , identifier[Class] operator[<] operator[?] operator[>] operator[SEP] operato... |
public void updateChain(ChainData inputChain) {
String chainname = inputChain.getName();
if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
Tr.debug(tc, "updateChain: " + chainname);
}
// Find the chain in the group.
for (int i = 0; i < this.chainArra... | class class_name[name] begin[{]
method[updateChain, return_type[void], modifier[public], parameter[inputChain]] begin[{]
local_variable[type[String], chainname]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isDebugEnabled, parameter[]]]] begin[{]... | Keyword[public] Keyword[void] identifier[updateChain] operator[SEP] identifier[ChainData] identifier[inputChain] operator[SEP] {
identifier[String] identifier[chainname] operator[=] identifier[inputChain] operator[SEP] identifier[getName] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identi... |
public List<Classification> listAll(String classificationName) {
assertArgumentNotNull("classificationName", classificationName);
return findClassificationMeta(classificationName, () -> {
return "listAll('" + classificationName + "')";
}).listAll();
} | class class_name[name] begin[{]
method[listAll, return_type[type[List]], modifier[public], parameter[classificationName]] begin[{]
call[.assertArgumentNotNull, parameter[literal["classificationName"], member[.classificationName]]]
return[call[.findClassificationMeta, parameter[member[.c... | Keyword[public] identifier[List] operator[<] identifier[Classification] operator[>] identifier[listAll] operator[SEP] identifier[String] identifier[classificationName] operator[SEP] {
identifier[assertArgumentNotNull] operator[SEP] literal[String] , identifier[classificationName] operator[SEP] operator[SEP] Key... |
public static String OSX_DOCK_ICON(MinecraftDirectory minecraftDir, Version version) throws IOException {
Set<Asset> assetIndex = Versions.resolveAssets(minecraftDir, version);
if (assetIndex == null)
return null;
return OSX_DOCK_ICON(minecraftDir, assetIndex);
} | class class_name[name] begin[{]
method[OSX_DOCK_ICON, return_type[type[String]], modifier[public static], parameter[minecraftDir, version]] begin[{]
local_variable[type[Set], assetIndex]
if[binary_operation[member[.assetIndex], ==, literal[null]]] begin[{]
return[literal[null]]
... | Keyword[public] Keyword[static] identifier[String] identifier[OSX_DOCK_ICON] operator[SEP] identifier[MinecraftDirectory] identifier[minecraftDir] , identifier[Version] identifier[version] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[Set] operator[<] identifier[Asset] operator[>] identifie... |
void handleGet(
Object value,
MatchSpaceKey msg,
EvalCache cache,
Object contextValue,
SearchResults result)
throws MatchingException, BadMessageFormatMatchingException {
if (tc.isEntryEnabled())
tc.entry(this,cclass, "handleGet",
new Object[] {value,msg,cache,contextValu... | class class_name[name] begin[{]
method[handleGet, return_type[void], modifier[default], parameter[value, msg, cache, contextValue, result]] begin[{]
if[call[tc.isEntryEnabled, parameter[]]] begin[{]
call[tc.entry, parameter[THIS[], member[.cclass], literal["handleGet"], ArrayCreator... | Keyword[void] identifier[handleGet] operator[SEP] identifier[Object] identifier[value] , identifier[MatchSpaceKey] identifier[msg] , identifier[EvalCache] identifier[cache] , identifier[Object] identifier[contextValue] , identifier[SearchResults] identifier[result] operator[SEP] Keyword[throws] identifier[MatchingE... |
public void marshall(BatchCheckLayerAvailabilityRequest batchCheckLayerAvailabilityRequest, ProtocolMarshaller protocolMarshaller) {
if (batchCheckLayerAvailabilityRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
proto... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[batchCheckLayerAvailabilityRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.batchCheckLayerAvailabilityRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=C... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[BatchCheckLayerAvailabilityRequest] identifier[batchCheckLayerAvailabilityRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[batchCheckLayerAvailabilityRequest] ... |
public Oneof getOneof(String name) {
for (Oneof oneof : getOneofs()) {
if (name.equals(oneof.getName())) {
return oneof;
}
}
return null;
} | class class_name[name] begin[{]
method[getOneof, return_type[type[Oneof]], modifier[public], parameter[name]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=getName, postfix_operators=[], prefix_o... | Keyword[public] identifier[Oneof] identifier[getOneof] operator[SEP] identifier[String] identifier[name] operator[SEP] {
Keyword[for] operator[SEP] identifier[Oneof] identifier[oneof] operator[:] identifier[getOneofs] operator[SEP] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[na... |
public List<PDefinition> getDefinitions(PPattern rp, PType ptype,
NameScope scope)
{
PDefinitionSet set = af.createPDefinitionSet();
set.addAll(af.createPPatternAssistant().getAllDefinitions(rp, ptype, scope));
List<PDefinition> result = new Vector<PDefinition>(set);
return result;
} | class class_name[name] begin[{]
method[getDefinitions, return_type[type[List]], modifier[public], parameter[rp, ptype, scope]] begin[{]
local_variable[type[PDefinitionSet], set]
call[set.addAll, parameter[call[af.createPPatternAssistant, parameter[]]]]
local_variable[type[List],... | Keyword[public] identifier[List] operator[<] identifier[PDefinition] operator[>] identifier[getDefinitions] operator[SEP] identifier[PPattern] identifier[rp] , identifier[PType] identifier[ptype] , identifier[NameScope] identifier[scope] operator[SEP] {
identifier[PDefinitionSet] identifier[set] operator[=] id... |
public boolean revert() {
try {
setWrongValueMessage(null);
setValue(propInfo.getPropertyValue(target));
updateValue();
return true;
} catch (Exception e) {
setWrongValueException(e);
return false;
}
} | class class_name[name] begin[{]
method[revert, return_type[type[boolean]], modifier[public], parameter[]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], value=null)], member=setWron... | Keyword[public] Keyword[boolean] identifier[revert] operator[SEP] operator[SEP] {
Keyword[try] {
identifier[setWrongValueMessage] operator[SEP] Other[null] operator[SEP] operator[SEP] identifier[setValue] operator[SEP] identifier[propInfo] operator[SEP] identifier[getPropertyValue] operator[SEP] ident... |
@Override
public void initialize(double[] initial, int numberOfParameters, double minimumFunctionValue) {
super.initialize(initial, numberOfParameters,minimumFunctionValue);
y.reshape(numberOfParameters,1);
xPrevious.reshape(numberOfParameters,1);
x.reshape(numberOfParameters,1);
// set the previous gradie... | class class_name[name] begin[{]
method[initialize, return_type[void], modifier[public], parameter[initial, numberOfParameters, minimumFunctionValue]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=initial, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), M... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[initialize] operator[SEP] Keyword[double] operator[SEP] operator[SEP] identifier[initial] , Keyword[int] identifier[numberOfParameters] , Keyword[double] identifier[minimumFunctionValue] operator[SEP] {
Keyword[super] operator[SEP] ide... |
public static String quote(String s) {
StringBuilder buf = new StringBuilder();
for (int i = 0; i < s.length(); i++) {
buf.append(quote(s.charAt(i)));
}
return buf.toString();
} | class class_name[name] begin[{]
method[quote, return_type[type[String]], modifier[public static], parameter[s]] begin[{]
local_variable[type[StringBuilder], buf]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(... | Keyword[public] Keyword[static] identifier[String] identifier[quote] operator[SEP] identifier[String] identifier[s] operator[SEP] {
identifier[StringBuilder] identifier[buf] operator[=] Keyword[new] identifier[StringBuilder] operator[SEP] operator[SEP] operator[SEP] Keyword[for] operator[SEP] Keyword[int] identi... |
@Override
public Set<Method> getMethods(MethodFilter methodFilter) {
return MethodUtils.getMethods(target, methodFilter);
} | class class_name[name] begin[{]
method[getMethods, return_type[type[Set]], modifier[public], parameter[methodFilter]] begin[{]
return[call[MethodUtils.getMethods, parameter[member[.target], member[.methodFilter]]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] identifier[Set] operator[<] identifier[Method] operator[>] identifier[getMethods] operator[SEP] identifier[MethodFilter] identifier[methodFilter] operator[SEP] {
Keyword[return] identifier[MethodUtils] operator[SEP] identifier[getMethods] operator[SEP] identifie... |
public List<ChallengeHandler> lookup(String location) {
List<ChallengeHandler> result = Collections.emptyList();
if (location != null) {
Node<ChallengeHandler, UriElement> resultNode = findBestMatchingNode(location);
if (resultNode != null) {
return resultNode.get... | class class_name[name] begin[{]
method[lookup, return_type[type[List]], modifier[public], parameter[location]] begin[{]
local_variable[type[List], result]
if[binary_operation[member[.location], !=, literal[null]]] begin[{]
local_variable[type[Node], resultNode]
... | Keyword[public] identifier[List] operator[<] identifier[ChallengeHandler] operator[>] identifier[lookup] operator[SEP] identifier[String] identifier[location] operator[SEP] {
identifier[List] operator[<] identifier[ChallengeHandler] operator[>] identifier[result] operator[=] identifier[Collections] operator[SEP]... |
public String putTempStream(Context context, InputStream in)
throws ServerException {
return worker.putTempStream(context, in);
} | class class_name[name] begin[{]
method[putTempStream, return_type[type[String]], modifier[public], parameter[context, in]] begin[{]
return[call[worker.putTempStream, parameter[member[.context], member[.in]]]]
end[}]
END[}] | Keyword[public] identifier[String] identifier[putTempStream] operator[SEP] identifier[Context] identifier[context] , identifier[InputStream] identifier[in] operator[SEP] Keyword[throws] identifier[ServerException] {
Keyword[return] identifier[worker] operator[SEP] identifier[putTempStream] operator[SEP] identif... |
@BetaApi
public final ListSslPoliciesPagedResponse listSslPolicies(String project) {
ListSslPoliciesHttpRequest request =
ListSslPoliciesHttpRequest.newBuilder().setProject(project).build();
return listSslPolicies(request);
} | class class_name[name] begin[{]
method[listSslPolicies, return_type[type[ListSslPoliciesPagedResponse]], modifier[final public], parameter[project]] begin[{]
local_variable[type[ListSslPoliciesHttpRequest], request]
return[call[.listSslPolicies, parameter[member[.request]]]]
end[}]
END[}] | annotation[@] identifier[BetaApi] Keyword[public] Keyword[final] identifier[ListSslPoliciesPagedResponse] identifier[listSslPolicies] operator[SEP] identifier[String] identifier[project] operator[SEP] {
identifier[ListSslPoliciesHttpRequest] identifier[request] operator[=] identifier[ListSslPoliciesHttpRequest] ... |
public synchronized void lock()
{
if (tc.isEntryEnabled())
SibTr.entry(tc, "lock", this);
boolean interrupted = false;
// Attempt to get a lock on the mutex.
// if we fail, then that is because the lock
// must be held exclusively.
while (!tryLock())
try
{
// Wait f... | class class_name[name] begin[{]
method[lock, return_type[void], modifier[synchronized public], parameter[]] begin[{]
if[call[tc.isEntryEnabled, parameter[]]] begin[{]
call[SibTr.entry, parameter[member[.tc], literal["lock"], THIS[]]]
else begin[{]
None
end[}]
... | Keyword[public] Keyword[synchronized] Keyword[void] identifier[lock] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[tc] operator[SEP] identifier[isEntryEnabled] operator[SEP] operator[SEP] operator[SEP] identifier[SibTr] operator[SEP] identifier[entry] operator[SEP] identifier[tc] , literal[... |
public <T> Graph<K, VV, EV> joinWithEdges(DataSet<Tuple3<K, K, T>> inputDataSet,
final EdgeJoinFunction<EV, T> edgeJoinFunction) {
DataSet<Edge<K, EV>> resultedEdges = this.getEdges()
.coGroup(inputDataSet).where(0, 1).equalTo(0, 1)
.with(new ApplyCoGroupToEdgeValues<>(edgeJoinFunction))
.name("Join ... | class class_name[name] begin[{]
method[joinWithEdges, return_type[type[Graph]], modifier[public], parameter[inputDataSet, edgeJoinFunction]] begin[{]
local_variable[type[DataSet], resultedEdges]
return[ClassCreator(arguments=[This(postfix_operators=[], prefix_operators=[], qualifier=None, selec... | Keyword[public] operator[<] identifier[T] operator[>] identifier[Graph] operator[<] identifier[K] , identifier[VV] , identifier[EV] operator[>] identifier[joinWithEdges] operator[SEP] identifier[DataSet] operator[<] identifier[Tuple3] operator[<] identifier[K] , identifier[K] , identifier[T] operator[>] operator[>]... |
static Given given(String text) {
reset();
final Given given = new Given(text);
sRoot = given;
return given;
} | class class_name[name] begin[{]
method[given, return_type[type[Given]], modifier[static], parameter[text]] begin[{]
call[.reset, parameter[]]
local_variable[type[Given], given]
assign[member[.sRoot], member[.given]]
return[member[.given]]
end[}]
END[}] | Keyword[static] identifier[Given] identifier[given] operator[SEP] identifier[String] identifier[text] operator[SEP] {
identifier[reset] operator[SEP] operator[SEP] operator[SEP] Keyword[final] identifier[Given] identifier[given] operator[=] Keyword[new] identifier[Given] operator[SEP] identifier[text] operator[S... |
protected boolean checkHandler(ZoneHandlerClass handler, ApiZone apiZone) {
return apiZone.getName().startsWith(handler.getZoneName());
} | class class_name[name] begin[{]
method[checkHandler, return_type[type[boolean]], modifier[protected], parameter[handler, apiZone]] begin[{]
return[call[apiZone.getName, parameter[]]]
end[}]
END[}] | Keyword[protected] Keyword[boolean] identifier[checkHandler] operator[SEP] identifier[ZoneHandlerClass] identifier[handler] , identifier[ApiZone] identifier[apiZone] operator[SEP] {
Keyword[return] identifier[apiZone] operator[SEP] identifier[getName] operator[SEP] operator[SEP] operator[SEP] identifier[startsW... |
public static List<List<CDKRMap>> getIsomorphMaps(IAtomContainer sourceGraph, IAtomContainer targetGraph,
boolean shouldMatchBonds) throws CDKException {
return search(sourceGraph, targetGraph, getBitSet(sourceGraph), getBitSet(targetGraph), true, true,
shouldMatchBonds);
} | class class_name[name] begin[{]
method[getIsomorphMaps, return_type[type[List]], modifier[public static], parameter[sourceGraph, targetGraph, shouldMatchBonds]] begin[{]
return[call[.search, parameter[member[.sourceGraph], member[.targetGraph], call[.getBitSet, parameter[member[.sourceGraph]]], call[.g... | Keyword[public] Keyword[static] identifier[List] operator[<] identifier[List] operator[<] identifier[CDKRMap] operator[>] operator[>] identifier[getIsomorphMaps] operator[SEP] identifier[IAtomContainer] identifier[sourceGraph] , identifier[IAtomContainer] identifier[targetGraph] , Keyword[boolean] identifier[shouldMa... |
@Nullable
private ServerHolder assignPrimary(
final DruidCoordinatorRuntimeParams params,
final DataSegment segment
)
{
ServerHolder topCandidate = null;
for (final Object2IntMap.Entry<String> entry : targetReplicants.object2IntEntrySet()) {
final int targetReplicantsInTier = entry.getIn... | class class_name[name] begin[{]
method[assignPrimary, return_type[type[ServerHolder]], modifier[private], parameter[params, segment]] begin[{]
local_variable[type[ServerHolder], topCandidate]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], decla... | annotation[@] identifier[Nullable] Keyword[private] identifier[ServerHolder] identifier[assignPrimary] operator[SEP] Keyword[final] identifier[DruidCoordinatorRuntimeParams] identifier[params] , Keyword[final] identifier[DataSegment] identifier[segment] operator[SEP] {
identifier[ServerHolder] identifier[topCan... |
@Override
public void truncateFile(String groupName, String path, long truncatedFileSize) {
StorageNodeInfo client = trackerClient.getUpdateStorage(groupName, path);
StorageTruncateCommand command = new StorageTruncateCommand(path, truncatedFileSize);
connectionManager.executeFdfsCmd(client.... | class class_name[name] begin[{]
method[truncateFile, return_type[void], modifier[public], parameter[groupName, path, truncatedFileSize]] begin[{]
local_variable[type[StorageNodeInfo], client]
local_variable[type[StorageTruncateCommand], command]
call[connectionManager.executeFdf... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[truncateFile] operator[SEP] identifier[String] identifier[groupName] , identifier[String] identifier[path] , Keyword[long] identifier[truncatedFileSize] operator[SEP] {
identifier[StorageNodeInfo] identifier[client] operator[=] identif... |
public static Long attemptUUIDParseHigh(BufferedString str) {
final byte[] buf = str.getBuffer();
int i=str.getOffset();
if ( i== -1 ) return markBad(str);
long hi=0;
if( buf[i++]!='-' ) return markBad(str);
hi = get2(hi,buf,(i+=2)-2);
hi = get2(hi,buf,(i+=2)-2);
if( buf[i++]!='-' ) retu... | class class_name[name] begin[{]
method[attemptUUIDParseHigh, return_type[type[Long]], modifier[public static], parameter[str]] begin[{]
local_variable[type[byte], buf]
local_variable[type[int], i]
if[binary_operation[member[.i], ==, literal[1]]] begin[{]
return[call[.markBad, pa... | Keyword[public] Keyword[static] identifier[Long] identifier[attemptUUIDParseHigh] operator[SEP] identifier[BufferedString] identifier[str] operator[SEP] {
Keyword[final] Keyword[byte] operator[SEP] operator[SEP] identifier[buf] operator[=] identifier[str] operator[SEP] identifier[getBuffer] operator[SEP] operato... |
public Observable<Page<VirtualNetworkTapInner>> listByResourceGroupAsync(final String resourceGroupName) {
return listByResourceGroupWithServiceResponseAsync(resourceGroupName)
.map(new Func1<ServiceResponse<Page<VirtualNetworkTapInner>>, Page<VirtualNetworkTapInner>>() {
@Override
... | class class_name[name] begin[{]
method[listByResourceGroupAsync, return_type[type[Observable]], modifier[public], parameter[resourceGroupName]] begin[{]
return[call[.listByResourceGroupWithServiceResponseAsync, parameter[member[.resourceGroupName]]]]
end[}]
END[}] | Keyword[public] identifier[Observable] operator[<] identifier[Page] operator[<] identifier[VirtualNetworkTapInner] operator[>] operator[>] identifier[listByResourceGroupAsync] operator[SEP] Keyword[final] identifier[String] identifier[resourceGroupName] operator[SEP] {
Keyword[return] identifier[listByResourceGr... |
protected void appendSARLElementType(XtendTypeDeclaration source, JvmDeclaredType target) {
addAnnotationSafe(target, SarlElementType.class, source.eClass().getClassifierID());
} | class class_name[name] begin[{]
method[appendSARLElementType, return_type[void], modifier[protected], parameter[source, target]] begin[{]
call[.addAnnotationSafe, parameter[member[.target], ClassReference(postfix_operators=[], prefix_operators=[], qualifier=, selectors=[], type=ReferenceType(ar... | Keyword[protected] Keyword[void] identifier[appendSARLElementType] operator[SEP] identifier[XtendTypeDeclaration] identifier[source] , identifier[JvmDeclaredType] identifier[target] operator[SEP] {
identifier[addAnnotationSafe] operator[SEP] identifier[target] , identifier[SarlElementType] operator[SEP] Keywor... |
public final AnalyzeEntitySentimentResponse analyzeEntitySentiment(Document document) {
AnalyzeEntitySentimentRequest request =
AnalyzeEntitySentimentRequest.newBuilder().setDocument(document).build();
return analyzeEntitySentiment(request);
} | class class_name[name] begin[{]
method[analyzeEntitySentiment, return_type[type[AnalyzeEntitySentimentResponse]], modifier[final public], parameter[document]] begin[{]
local_variable[type[AnalyzeEntitySentimentRequest], request]
return[call[.analyzeEntitySentiment, parameter[member[.request]]]]... | Keyword[public] Keyword[final] identifier[AnalyzeEntitySentimentResponse] identifier[analyzeEntitySentiment] operator[SEP] identifier[Document] identifier[document] operator[SEP] {
identifier[AnalyzeEntitySentimentRequest] identifier[request] operator[=] identifier[AnalyzeEntitySentimentRequest] operator[SEP] id... |
public static void construct(BaseMessageEndpointFactory factory,
MessageEndpointBase messageEndpointBase,
int recoveryId,
EJSContainer container,
BeanMetaData beanMetaData,
... | class class_name[name] begin[{]
method[construct, return_type[void], modifier[public static], parameter[factory, messageEndpointBase, recoveryId, container, beanMetaData, pmiBean, wrapperManager, rrsTransactional]] begin[{]
assign[member[messageEndpointBase.container], member[.container]]
... | Keyword[public] Keyword[static] Keyword[void] identifier[construct] operator[SEP] identifier[BaseMessageEndpointFactory] identifier[factory] , identifier[MessageEndpointBase] identifier[messageEndpointBase] , Keyword[int] identifier[recoveryId] , identifier[EJSContainer] identifier[container] , identifier[BeanMetaD... |
@Override
public boolean exists()
{
ClassLoader loader = Thread.currentThread().getContextClassLoader();
return loader.getResource(getTrimPath()) != null;
} | class class_name[name] begin[{]
method[exists, return_type[type[boolean]], modifier[public], parameter[]] begin[{]
local_variable[type[ClassLoader], loader]
return[binary_operation[call[loader.getResource, parameter[call[.getTrimPath, parameter[]]]], !=, literal[null]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] Keyword[boolean] identifier[exists] operator[SEP] operator[SEP] {
identifier[ClassLoader] identifier[loader] operator[=] identifier[Thread] operator[SEP] identifier[currentThread] operator[SEP] operator[SEP] operator[SEP] identifier[getContextClassLoader] operat... |
public InstagramSubscription callback(String callback) {
Preconditions.checkValidUrl(callback, "Invalid Callback Url");
this.params.put(Constants.CALLBACK_URL, callback);
return this;
} | class class_name[name] begin[{]
method[callback, return_type[type[InstagramSubscription]], modifier[public], parameter[callback]] begin[{]
call[Preconditions.checkValidUrl, parameter[member[.callback], literal["Invalid Callback Url"]]]
THIS[member[None.params]call[None.put, para... | Keyword[public] identifier[InstagramSubscription] identifier[callback] operator[SEP] identifier[String] identifier[callback] operator[SEP] {
identifier[Preconditions] operator[SEP] identifier[checkValidUrl] operator[SEP] identifier[callback] , literal[String] operator[SEP] operator[SEP] Keyword[this] operator[S... |
private Object getScriptResult(String script, ScriptEngine engine) throws ScriptException {
String scriptToExecute = script.substring(script.indexOf(":") + 1);
return engine.eval(scriptToExecute);
} | class class_name[name] begin[{]
method[getScriptResult, return_type[type[Object]], modifier[private], parameter[script, engine]] begin[{]
local_variable[type[String], scriptToExecute]
return[call[engine.eval, parameter[member[.scriptToExecute]]]]
end[}]
END[}] | Keyword[private] identifier[Object] identifier[getScriptResult] operator[SEP] identifier[String] identifier[script] , identifier[ScriptEngine] identifier[engine] operator[SEP] Keyword[throws] identifier[ScriptException] {
identifier[String] identifier[scriptToExecute] operator[=] identifier[script] operator[SEP... |
@Override
public String loadDataFromNetwork() throws Exception {
try {
Ln.d("Call web service " + url);
return IOUtils.toString(new InputStreamReader(new URL(url).openStream(), CharEncoding.UTF_8));
} catch (final MalformedURLException e) {
Ln.e(e, "Unable to crea... | class class_name[name] begin[{]
method[loadDataFromNetwork, return_type[type[String]], modifier[public], parameter[]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[BinaryOperation(operandl=Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selec... | annotation[@] identifier[Override] Keyword[public] identifier[String] identifier[loadDataFromNetwork] operator[SEP] operator[SEP] Keyword[throws] identifier[Exception] {
Keyword[try] {
identifier[Ln] operator[SEP] identifier[d] operator[SEP] literal[String] operator[+] identifier[url] operator[SEP] op... |
public static PrintWriter newPrintWriter(Path self, String charset) throws IOException {
return new GroovyPrintWriter(newWriter(self, charset));
} | class class_name[name] begin[{]
method[newPrintWriter, return_type[type[PrintWriter]], modifier[public static], parameter[self, charset]] begin[{]
return[ClassCreator(arguments=[MethodInvocation(arguments=[MemberReference(member=self, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])... | Keyword[public] Keyword[static] identifier[PrintWriter] identifier[newPrintWriter] operator[SEP] identifier[Path] identifier[self] , identifier[String] identifier[charset] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[return] Keyword[new] identifier[GroovyPrintWriter] operator[SEP] identifier[... |
@Override
public void layoutViews(RecyclerView.Recycler recycler, RecyclerView.State state,
VirtualLayoutManager.LayoutStateWrapper layoutState, LayoutChunkResult result,
LayoutManagerHelper helper) {
// reach the end of this layout
if (isOutOf... | class class_name[name] begin[{]
method[layoutViews, return_type[void], modifier[public], parameter[recycler, state, layoutState, result, helper]] begin[{]
if[call[.isOutOfRange, parameter[call[layoutState.getCurrentPosition, parameter[]]]]] begin[{]
return[None]
else begin[{... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[layoutViews] operator[SEP] identifier[RecyclerView] operator[SEP] identifier[Recycler] identifier[recycler] , identifier[RecyclerView] operator[SEP] identifier[State] identifier[state] , identifier[VirtualLayoutManager] operator[SEP] identifi... |
public static BtcFormat getMicroInstance(int scale, int... groups) {
return getInstance(MICROCOIN_SCALE, defaultLocale(), scale, boxAsList(groups));
} | class class_name[name] begin[{]
method[getMicroInstance, return_type[type[BtcFormat]], modifier[public static], parameter[scale, groups]] begin[{]
return[call[.getInstance, parameter[member[.MICROCOIN_SCALE], call[.defaultLocale, parameter[]], member[.scale], call[.boxAsList, parameter[member[.groups]]... | Keyword[public] Keyword[static] identifier[BtcFormat] identifier[getMicroInstance] operator[SEP] Keyword[int] identifier[scale] , Keyword[int] operator[...] identifier[groups] operator[SEP] {
Keyword[return] identifier[getInstance] operator[SEP] identifier[MICROCOIN_SCALE] , identifier[defaultLocale] operator[... |
private void handleEvent(PrimitiveEvent event) {
log.trace("Received {}", event);
Set<Consumer<PrimitiveEvent>> listeners = eventListeners.get(event.type());
if (listeners != null) {
listeners.forEach(l -> l.accept(event));
}
} | class class_name[name] begin[{]
method[handleEvent, return_type[void], modifier[private], parameter[event]] begin[{]
call[log.trace, parameter[literal["Received {}"], member[.event]]]
local_variable[type[Set], listeners]
if[binary_operation[member[.listeners], !=, litera... | Keyword[private] Keyword[void] identifier[handleEvent] operator[SEP] identifier[PrimitiveEvent] identifier[event] operator[SEP] {
identifier[log] operator[SEP] identifier[trace] operator[SEP] literal[String] , identifier[event] operator[SEP] operator[SEP] identifier[Set] operator[<] identifier[Consumer] operato... |
private void writeChunk(String spaceId, ChunkInputStream chunk)
throws NotFoundException {
// Write chunk as a temp file
String chunkId = chunk.getChunkId();
File chunkFile = IOUtil.writeStreamToFile(chunk);
try {
String chunkChecksum = getChunkChecksum(chunkFile);
... | class class_name[name] begin[{]
method[writeChunk, return_type[void], modifier[private], parameter[spaceId, chunk]] begin[{]
local_variable[type[String], chunkId]
local_variable[type[File], chunkFile]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDecl... | Keyword[private] Keyword[void] identifier[writeChunk] operator[SEP] identifier[String] identifier[spaceId] , identifier[ChunkInputStream] identifier[chunk] operator[SEP] Keyword[throws] identifier[NotFoundException] {
identifier[String] identifier[chunkId] operator[=] identifier[chunk] operator[SEP] identifier[... |
public ArrayList<OvhNetwork> project_serviceName_network_public_GET(String serviceName) throws IOException {
String qPath = "/cloud/project/{serviceName}/network/public";
StringBuilder sb = path(qPath, serviceName);
String resp = exec(qPath, "GET", sb.toString(), null);
return convertTo(resp, t7);
} | class class_name[name] begin[{]
method[project_serviceName_network_public_GET, return_type[type[ArrayList]], modifier[public], parameter[serviceName]] begin[{]
local_variable[type[String], qPath]
local_variable[type[StringBuilder], sb]
local_variable[type[String], resp]
return[c... | Keyword[public] identifier[ArrayList] operator[<] identifier[OvhNetwork] operator[>] identifier[project_serviceName_network_public_GET] operator[SEP] identifier[String] identifier[serviceName] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[String] identifier[qPath] operator[=] literal[String]... |
public static double[][] cor(double[][] data, double[] mu) {
double[][] sigma = cov(data, mu);
int n = data[0].length;
double[] sd = new double[n];
for (int i = 0; i < n; i++) {
sd[i] = sqrt(sigma[i][i]);
}
for (int i = 0; i < n; i++) {
for (int ... | class class_name[name] begin[{]
method[cor, return_type[type[double]], modifier[public static], parameter[data, mu]] begin[{]
local_variable[type[double], sigma]
local_variable[type[int], n]
local_variable[type[double], sd]
ForStatement(body=BlockStatement(label=None, statements... | Keyword[public] Keyword[static] Keyword[double] operator[SEP] operator[SEP] operator[SEP] operator[SEP] identifier[cor] operator[SEP] Keyword[double] operator[SEP] operator[SEP] operator[SEP] operator[SEP] identifier[data] , Keyword[double] operator[SEP] operator[SEP] identifier[mu] operator[SEP] {
Keyword[doub... |
public void addFilter(String name, String classname,
Map<String, String> parameters) {
final String[] USER_FACING_URLS = { "*.html", "*.jsp" };
defineFilter(webAppContext, name, classname, parameters, USER_FACING_URLS);
final String[] ALL_URLS = { "/*" };
for (Map.Entry<Context, Boolean> e : defa... | class class_name[name] begin[{]
method[addFilter, return_type[void], modifier[public], parameter[name, classname, parameters]] begin[{]
local_variable[type[String], USER_FACING_URLS]
call[.defineFilter, parameter[member[.webAppContext], member[.name], member[.classname], member[.paramet... | Keyword[public] Keyword[void] identifier[addFilter] operator[SEP] identifier[String] identifier[name] , identifier[String] identifier[classname] , identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[parameters] operator[SEP] {
Keyword[final] identifier[String] operator[S... |
public void okResponse(String responseCode, String message) {
untagged();
message(OK);
responseCode(responseCode);
message(message);
end();
} | class class_name[name] begin[{]
method[okResponse, return_type[void], modifier[public], parameter[responseCode, message]] begin[{]
call[.untagged, parameter[]]
call[.message, parameter[member[.OK]]]
call[.responseCode, parameter[member[.responseCode]]]
... | Keyword[public] Keyword[void] identifier[okResponse] operator[SEP] identifier[String] identifier[responseCode] , identifier[String] identifier[message] operator[SEP] {
identifier[untagged] operator[SEP] operator[SEP] operator[SEP] identifier[message] operator[SEP] identifier[OK] operator[SEP] operator[SEP] iden... |
public void deleteBulkDocsAsync(List<String> indexList,
List<String> typeList, QueryBuilder filterQueryBuilder,
ActionListener<BulkResponse> bulkResponseActionListener) {
indexList.forEach(
index -> typeList.forEach(type -> deleteBulkDocsAsync(index,
... | class class_name[name] begin[{]
method[deleteBulkDocsAsync, return_type[void], modifier[public], parameter[indexList, typeList, filterQueryBuilder, bulkResponseActionListener]] begin[{]
call[indexList.forEach, parameter[LambdaExpression(body=MethodInvocation(arguments=[LambdaExpression(body=Met... | Keyword[public] Keyword[void] identifier[deleteBulkDocsAsync] operator[SEP] identifier[List] operator[<] identifier[String] operator[>] identifier[indexList] , identifier[List] operator[<] identifier[String] operator[>] identifier[typeList] , identifier[QueryBuilder] identifier[filterQueryBuilder] , identifier[Actio... |
@Override
public EJSWrapperCommon internalCreateWrapper(BeanId beanId)
throws CreateException, RemoteException, CSIException
{
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
Tr.entry(tc, "internalCreateWrapper : " + beanId);
// -----------------... | class class_name[name] begin[{]
method[internalCreateWrapper, return_type[type[EJSWrapperCommon]], modifier[public], parameter[beanId]] begin[{]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{]
call[Tr.ent... | annotation[@] identifier[Override] Keyword[public] identifier[EJSWrapperCommon] identifier[internalCreateWrapper] operator[SEP] identifier[BeanId] identifier[beanId] operator[SEP] Keyword[throws] identifier[CreateException] , identifier[RemoteException] , identifier[CSIException] {
Keyword[if] operator[SEP] id... |
public String getEffectiveProperty(CmsClientSitemapEntry entry, String name) {
CmsClientProperty prop = getEffectivePropertyObject(entry, name);
if (prop == null) {
return null;
}
return prop.getEffectiveValue();
} | class class_name[name] begin[{]
method[getEffectiveProperty, return_type[type[String]], modifier[public], parameter[entry, name]] begin[{]
local_variable[type[CmsClientProperty], prop]
if[binary_operation[member[.prop], ==, literal[null]]] begin[{]
return[literal[null]]
... | Keyword[public] identifier[String] identifier[getEffectiveProperty] operator[SEP] identifier[CmsClientSitemapEntry] identifier[entry] , identifier[String] identifier[name] operator[SEP] {
identifier[CmsClientProperty] identifier[prop] operator[=] identifier[getEffectivePropertyObject] operator[SEP] identifier[e... |
public Variable slice(int dim, int value) throws InvalidRangeException {
if ((dim < 0) || (dim >= shape.length))
throw new InvalidRangeException("Slice dim invalid= " + dim);
// ok to make slice of record dimension with length 0
boolean recordSliceOk = false;
if ((dim == 0) && (value == 0)) {
... | class class_name[name] begin[{]
method[slice, return_type[type[Variable]], modifier[public], parameter[dim, value]] begin[{]
if[binary_operation[binary_operation[member[.dim], <, literal[0]], ||, binary_operation[member[.dim], >=, member[shape.length]]]] begin[{]
ThrowStatement(expression=Class... | Keyword[public] identifier[Variable] identifier[slice] operator[SEP] Keyword[int] identifier[dim] , Keyword[int] identifier[value] operator[SEP] Keyword[throws] identifier[InvalidRangeException] {
Keyword[if] operator[SEP] operator[SEP] identifier[dim] operator[<] Other[0] operator[SEP] operator[||] operator[SE... |
@SafeVarargs
public static <T> T randomFrom(T[] array, T... excludes) {
return randomFrom(array, Arrays.asList(excludes));
} | class class_name[name] begin[{]
method[randomFrom, return_type[type[T]], modifier[public static], parameter[array, excludes]] begin[{]
return[call[.randomFrom, parameter[member[.array], call[Arrays.asList, parameter[member[.excludes]]]]]]
end[}]
END[}] | annotation[@] identifier[SafeVarargs] Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[T] identifier[randomFrom] operator[SEP] identifier[T] operator[SEP] operator[SEP] identifier[array] , identifier[T] operator[...] identifier[excludes] operator[SEP] {
Keyword[return] identifier... |
public synchronized long read(OutputStream stream, long length) throws IOException
{
if (true)
throw new IOException("Not implemented");
boolean recreateBuffer = true;
try
{
if (fileIn != null && stream instanceof FileOutputStream)
{
// use NI... | class class_name[name] begin[{]
method[read, return_type[type[long]], modifier[synchronized public], parameter[stream, length]] begin[{]
if[literal[true]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], ... | Keyword[public] Keyword[synchronized] Keyword[long] identifier[read] operator[SEP] identifier[OutputStream] identifier[stream] , Keyword[long] identifier[length] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[if] operator[SEP] literal[boolean] operator[SEP] Keyword[throw] Keyword[new] identifie... |
public void verify(ServerStoreConfiguration serverConfiguration, ServerStoreConfiguration clientConfiguration)
throws InvalidServerStoreConfigurationException {
StringBuilder sb = new StringBuilder("Existing ServerStore configuration is not compatible with the desired configuration: ");
if (!serverConfig... | class class_name[name] begin[{]
method[verify, return_type[void], modifier[public], parameter[serverConfiguration, clientConfiguration]] begin[{]
local_variable[type[StringBuilder], sb]
if[call[serverConfiguration.isCompatible, parameter[member[.clientConfiguration], member[.sb]]]] begi... | Keyword[public] Keyword[void] identifier[verify] operator[SEP] identifier[ServerStoreConfiguration] identifier[serverConfiguration] , identifier[ServerStoreConfiguration] identifier[clientConfiguration] operator[SEP] Keyword[throws] identifier[InvalidServerStoreConfigurationException] {
identifier[StringBuilder... |
@CheckForNull
public static InstallState valueOf(@Nonnull String name) {
for (InstallState state : all()) {
if (name.equals(state.name)) {
return state;
}
}
return null;
} | class class_name[name] begin[{]
method[valueOf, return_type[type[InstallState]], modifier[public static], parameter[name]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=name, postfix_operators=[], prefix_operat... | annotation[@] identifier[CheckForNull] Keyword[public] Keyword[static] identifier[InstallState] identifier[valueOf] operator[SEP] annotation[@] identifier[Nonnull] identifier[String] identifier[name] operator[SEP] {
Keyword[for] operator[SEP] identifier[InstallState] identifier[state] operator[:] identifier[all... |
public static UUID from128(byte[] data, int offset, boolean littleEndian)
{
if (data == null || offset < 0 || data.length <= (offset + 15) || (Integer.MAX_VALUE - 15) < offset)
{
return null;
}
String uuid;
if (littleEndian)
{
uuid = String.f... | class class_name[name] begin[{]
method[from128, return_type[type[UUID]], modifier[public static], parameter[data, offset, littleEndian]] begin[{]
if[binary_operation[binary_operation[binary_operation[binary_operation[member[.data], ==, literal[null]], ||, binary_operation[member[.offset], <, li... | Keyword[public] Keyword[static] identifier[UUID] identifier[from128] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[data] , Keyword[int] identifier[offset] , Keyword[boolean] identifier[littleEndian] operator[SEP] {
Keyword[if] operator[SEP] identifier[data] operator[==] Other[null] operato... |
@Override
public ConfusionMessage createCNF() {
ConfusionMessage msg = new ConfusionMessageImpl(_CNF_HOLDER.mandatoryCodes, _CNF_HOLDER.mandatoryVariableCodes,
_CNF_HOLDER.optionalCodes, _CNF_HOLDER.mandatoryCodeToIndex, _CNF_HOLDER.mandatoryVariableCodeToIndex,
_CNF_HOLDER.o... | class class_name[name] begin[{]
method[createCNF, return_type[type[ConfusionMessage]], modifier[public], parameter[]] begin[{]
local_variable[type[ConfusionMessage], msg]
return[member[.msg]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] identifier[ConfusionMessage] identifier[createCNF] operator[SEP] operator[SEP] {
identifier[ConfusionMessage] identifier[msg] operator[=] Keyword[new] identifier[ConfusionMessageImpl] operator[SEP] identifier[_CNF_HOLDER] operator[SEP] identifier[mandatoryCodes]... |
public void marshall(CreateLogStreamRequest createLogStreamRequest, ProtocolMarshaller protocolMarshaller) {
if (createLogStreamRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(createLogStre... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[createLogStreamRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.createLogStreamRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[L... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[CreateLogStreamRequest] identifier[createLogStreamRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[createLogStreamRequest] operator[==] Other[null] operator[SE... |
@Nonnull
@Nonempty
@Deprecated
public static String getFieldName (@Nonnull @Nonempty final String sBaseName)
{
ValueEnforcer.notEmpty (sBaseName, "BaseName");
return sBaseName;
} | class class_name[name] begin[{]
method[getFieldName, return_type[type[String]], modifier[public static], parameter[sBaseName]] begin[{]
call[ValueEnforcer.notEmpty, parameter[member[.sBaseName], literal["BaseName"]]]
return[member[.sBaseName]]
end[}]
END[}] | annotation[@] identifier[Nonnull] annotation[@] identifier[Nonempty] annotation[@] identifier[Deprecated] Keyword[public] Keyword[static] identifier[String] identifier[getFieldName] operator[SEP] annotation[@] identifier[Nonnull] annotation[@] identifier[Nonempty] Keyword[final] identifier[String] identifier[sBaseName]... |
public Credentials getCredentials(AuthScope scope)
{
serverF.setText(scope.getHost()+":"+scope.getPort());
String realmName = scope.getRealm();
if (realmName == null) {
realmName = "THREDDS Data Server";
}
realmF.setText(realmName);
dialog.setVisible( true);
if (pwa == null) throw new... | class class_name[name] begin[{]
method[getCredentials, return_type[type[Credentials]], modifier[public], parameter[scope]] begin[{]
call[serverF.setText, parameter[binary_operation[binary_operation[call[scope.getHost, parameter[]], +, literal[":"]], +, call[scope.getPort, parameter[]]]]]
... | Keyword[public] identifier[Credentials] identifier[getCredentials] operator[SEP] identifier[AuthScope] identifier[scope] operator[SEP] {
identifier[serverF] operator[SEP] identifier[setText] operator[SEP] identifier[scope] operator[SEP] identifier[getHost] operator[SEP] operator[SEP] operator[+] literal[String] ... |
@Override
public EClass getIfcDuctSegment() {
if (ifcDuctSegmentEClass == null) {
ifcDuctSegmentEClass = (EClass) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI)
.getEClassifiers().get(202);
}
return ifcDuctSegmentEClass;
} | class class_name[name] begin[{]
method[getIfcDuctSegment, return_type[type[EClass]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.ifcDuctSegmentEClass], ==, literal[null]]] begin[{]
assign[member[.ifcDuctSegmentEClass], Cast(expression=MethodInvoca... | annotation[@] identifier[Override] Keyword[public] identifier[EClass] identifier[getIfcDuctSegment] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[ifcDuctSegmentEClass] operator[==] Other[null] operator[SEP] {
identifier[ifcDuctSegmentEClass] operator[=] operator[SEP] identifier[EC... |
private void setTrimLeadingWhitespacesByReflection(Renderer result, boolean trimLeadingCommonSourceWhitespaces) {
String fieldName = "trimLeadingWhitespace";
if (logger.isDebugEnabled()) {
logger.debug("Try setting '{}' field to '{}' for '{}' by reflection.", fieldName, trimLeadingCommonSour... | class class_name[name] begin[{]
method[setTrimLeadingWhitespacesByReflection, return_type[void], modifier[private], parameter[result, trimLeadingCommonSourceWhitespaces]] begin[{]
local_variable[type[String], fieldName]
if[call[logger.isDebugEnabled, parameter[]]] begin[{]
... | Keyword[private] Keyword[void] identifier[setTrimLeadingWhitespacesByReflection] operator[SEP] identifier[Renderer] identifier[result] , Keyword[boolean] identifier[trimLeadingCommonSourceWhitespaces] operator[SEP] {
identifier[String] identifier[fieldName] operator[=] literal[String] operator[SEP] Keyword[if] ... |
public void setMode(int mode) {
// check arg
switch (mode) {
case MODE_EXACT:
case MODE_JCOMPOUNDMAPPER:
break;
default:
throw new IllegalArgumentException("Invalid mode specified!");
}
this.mode = mode;
// re-g... | class class_name[name] begin[{]
method[setMode, return_type[void], modifier[public], parameter[mode]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=['MODE_EXACT', 'MODE_JCOMPOUNDMAPPER'], statements=[BreakStatement(goto=None, label=None)]), SwitchStatementCase(case=[], statements=[ThrowState... | Keyword[public] Keyword[void] identifier[setMode] operator[SEP] Keyword[int] identifier[mode] operator[SEP] {
Keyword[switch] operator[SEP] identifier[mode] operator[SEP] {
Keyword[case] identifier[MODE_EXACT] operator[:] Keyword[case] identifier[MODE_JCOMPOUNDMAPPER] operator[:] Keyword[break] oper... |
public FollowPlaylistRequest.Builder followPlaylist(String owner_id, String playlist_id, boolean public_) {
return new FollowPlaylistRequest.Builder(accessToken)
.setDefaults(httpManager, scheme, host, port)
.owner_id(owner_id)
.playlist_id(playlist_id)
.public_(publi... | class class_name[name] begin[{]
method[followPlaylist, return_type[type[FollowPlaylistRequest]], modifier[public], parameter[owner_id, playlist_id, public_]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=accessToken, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])]... | Keyword[public] identifier[FollowPlaylistRequest] operator[SEP] identifier[Builder] identifier[followPlaylist] operator[SEP] identifier[String] identifier[owner_id] , identifier[String] identifier[playlist_id] , Keyword[boolean] identifier[public_] operator[SEP] {
Keyword[return] Keyword[new] identifier[Follow... |
public HttpMessage cookie(final Cookie cookie) {
this.cookies.put(cookie.getName(), cookie);
setHeader(
HttpMessageHeaders.HTTP_COOKIE_PREFIX + cookie.getName(),
cookieConverter.getCookieString(cookie));
return this;
} | class class_name[name] begin[{]
method[cookie, return_type[type[HttpMessage]], modifier[public], parameter[cookie]] begin[{]
THIS[member[None.cookies]call[None.put, parameter[call[cookie.getName, parameter[]], member[.cookie]]]]
call[.setHeader, parameter[binary_operation[member... | Keyword[public] identifier[HttpMessage] identifier[cookie] operator[SEP] Keyword[final] identifier[Cookie] identifier[cookie] operator[SEP] {
Keyword[this] operator[SEP] identifier[cookies] operator[SEP] identifier[put] operator[SEP] identifier[cookie] operator[SEP] identifier[getName] operator[SEP] operator[SEP... |
public static DiscountCurveInterpolation createDiscountCurveFromZeroRates(String name, double[] times, double[] givenZeroRates) {
double[] givenDiscountFactors = new double[givenZeroRates.length];
for(int timeIndex=0; timeIndex<times.length;timeIndex++) {
givenDiscountFactors[timeIndex] = Math.exp(- givenZeroRa... | class class_name[name] begin[{]
method[createDiscountCurveFromZeroRates, return_type[type[DiscountCurveInterpolation]], modifier[public static], parameter[name, times, givenZeroRates]] begin[{]
local_variable[type[double], givenDiscountFactors]
ForStatement(body=BlockStatement(label=None, state... | Keyword[public] Keyword[static] identifier[DiscountCurveInterpolation] identifier[createDiscountCurveFromZeroRates] operator[SEP] identifier[String] identifier[name] , Keyword[double] operator[SEP] operator[SEP] identifier[times] , Keyword[double] operator[SEP] operator[SEP] identifier[givenZeroRates] operator[SEP] ... |
private void createFunction(String name, GeometryFunction function) {
try {
Function.create(getGeoPackage().getConnection().getConnection(),
name, function);
} catch (SQLException e) {
log.log(Level.SEVERE, "Failed to create function: " + name, e);
}
} | class class_name[name] begin[{]
method[createFunction, return_type[void], modifier[private], parameter[name, function]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MethodInvocation(arguments=[], member=getGeoPackage, postfix_operators=[], prefix_operators=[],... | Keyword[private] Keyword[void] identifier[createFunction] operator[SEP] identifier[String] identifier[name] , identifier[GeometryFunction] identifier[function] operator[SEP] {
Keyword[try] {
identifier[Function] operator[SEP] identifier[create] operator[SEP] identifier[getGeoPackage] operator[SEP] op... |
@Nonnull
public CascadingStyleSheet addNamespaceRule (@Nonnegative final int nIndex,
@Nonnull final CSSNamespaceRule aNamespaceRule)
{
ValueEnforcer.isGE0 (nIndex, "Index");
ValueEnforcer.notNull (aNamespaceRule, "NamespaceRule");
if (nIndex >= getNamespac... | class class_name[name] begin[{]
method[addNamespaceRule, return_type[type[CascadingStyleSheet]], modifier[public], parameter[nIndex, aNamespaceRule]] begin[{]
call[ValueEnforcer.isGE0, parameter[member[.nIndex], literal["Index"]]]
call[ValueEnforcer.notNull, parameter[member[.aN... | annotation[@] identifier[Nonnull] Keyword[public] identifier[CascadingStyleSheet] identifier[addNamespaceRule] operator[SEP] annotation[@] identifier[Nonnegative] Keyword[final] Keyword[int] identifier[nIndex] , annotation[@] identifier[Nonnull] Keyword[final] identifier[CSSNamespaceRule] identifier[aNamespaceRule] op... |
@Override
public void write(List<? extends File> items) throws Exception {
log.info("starting to write {} file(s) to duracloud", items.size());
for (final File file : items) {
restoreFile(file, watchDir);
}
} | class class_name[name] begin[{]
method[write, return_type[void], modifier[public], parameter[items]] begin[{]
call[log.info, parameter[literal["starting to write {} file(s) to duracloud"], call[items.size, parameter[]]]]
ForStatement(body=BlockStatement(label=None, statements=[Statement... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[write] operator[SEP] identifier[List] operator[<] operator[?] Keyword[extends] identifier[File] operator[>] identifier[items] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[log] operator[SEP] identifier[info] operator[S... |
@WithBridgeMethods(List.class)
@Deprecated
public RunList<RunT> getBuildsByTimestamp(long start, long end) {
return getBuilds().byTimestamp(start,end);
} | class class_name[name] begin[{]
method[getBuildsByTimestamp, return_type[type[RunList]], modifier[public], parameter[start, end]] begin[{]
return[call[.getBuilds, parameter[]]]
end[}]
END[}] | annotation[@] identifier[WithBridgeMethods] operator[SEP] identifier[List] operator[SEP] Keyword[class] operator[SEP] annotation[@] identifier[Deprecated] Keyword[public] identifier[RunList] operator[<] identifier[RunT] operator[>] identifier[getBuildsByTimestamp] operator[SEP] Keyword[long] identifier[start] , Keywor... |
public static SettingsInsert get(Map<String, String[]> clArgs)
{
String[] params = clArgs.remove("-insert");
if (params == null)
return new SettingsInsert(new InsertOptions());
InsertOptions options = GroupedOptions.select(params, new InsertOptions());
if (options == nul... | class class_name[name] begin[{]
method[get, return_type[type[SettingsInsert]], modifier[public static], parameter[clArgs]] begin[{]
local_variable[type[String], params]
if[binary_operation[member[.params], ==, literal[null]]] begin[{]
return[ClassCreator(arguments=[ClassCreator(argument... | Keyword[public] Keyword[static] identifier[SettingsInsert] identifier[get] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[String] operator[SEP] operator[SEP] operator[>] identifier[clArgs] operator[SEP] {
identifier[String] operator[SEP] operator[SEP] identifier[params] operator[=] id... |
public void marshall(ListJobsRequest listJobsRequest, ProtocolMarshaller protocolMarshaller) {
if (listJobsRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(listJobsRequest.getMaxResults(), M... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[listJobsRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.listJobsRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[ListJobsRequest] identifier[listJobsRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[listJobsRequest] operator[==] Other[null] operator[SEP] {
Keywo... |
public static Result onBackground(Action action) {
final HandlerPoster poster = getBackgroundPoster();
if (Looper.myLooper() == poster.getLooper()) {
action.call();
return new ActionAsyncTask(action, true);
}
ActionAsyncTask task = new ActionAsyncTask(action);
... | class class_name[name] begin[{]
method[onBackground, return_type[type[Result]], modifier[public static], parameter[action]] begin[{]
local_variable[type[HandlerPoster], poster]
if[binary_operation[call[Looper.myLooper, parameter[]], ==, call[poster.getLooper, parameter[]]]] begin[{]
... | Keyword[public] Keyword[static] identifier[Result] identifier[onBackground] operator[SEP] identifier[Action] identifier[action] operator[SEP] {
Keyword[final] identifier[HandlerPoster] identifier[poster] operator[=] identifier[getBackgroundPoster] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SE... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.