code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
public StylingPolicy getStylePolicy(ResultHierarchy hier, StyleLibrary stylelib) {
Database db = ResultUtil.findDatabase(hier);
AutomaticEvaluation.ensureClusteringResult(db, db);
List<Clustering<? extends Model>> clusterings = Clustering.getClusteringResults(db);
if(clusterings.isEmpty()) {
throw... | class class_name[name] begin[{]
method[getStylePolicy, return_type[type[StylingPolicy]], modifier[public], parameter[hier, stylelib]] begin[{]
local_variable[type[Database], db]
call[AutomaticEvaluation.ensureClusteringResult, parameter[member[.db], member[.db]]]
local_variable[... | Keyword[public] identifier[StylingPolicy] identifier[getStylePolicy] operator[SEP] identifier[ResultHierarchy] identifier[hier] , identifier[StyleLibrary] identifier[stylelib] operator[SEP] {
identifier[Database] identifier[db] operator[=] identifier[ResultUtil] operator[SEP] identifier[findDatabase] operator[S... |
public TabbedPanel2 getTabbedWork() {
if (tabbedWork == null) {
tabbedWork = new TabbedPanel2();
tabbedWork.setPreferredSize(new Dimension(600, 400));
tabbedWork.setName("tabbedWork");
tabbedWork.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
}
return tabbedWork;
} | class class_name[name] begin[{]
method[getTabbedWork, return_type[type[TabbedPanel2]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.tabbedWork], ==, literal[null]]] begin[{]
assign[member[.tabbedWork], ClassCreator(arguments=[], body=None, construc... | Keyword[public] identifier[TabbedPanel2] identifier[getTabbedWork] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[tabbedWork] operator[==] Other[null] operator[SEP] {
identifier[tabbedWork] operator[=] Keyword[new] identifier[TabbedPanel2] operator[SEP] operator[SEP] operator[SEP] ... |
@Override
public void eUnset(int featureID) {
switch (featureID) {
case AfplibPackage.BOG__OEG_NAME:
setOEGName(OEG_NAME_EDEFAULT);
return;
case AfplibPackage.BOG__TRIPLETS:
getTriplets().clear();
return;
}
super.eUnset(featureID);
} | class class_name[name] begin[{]
method[eUnset, return_type[void], modifier[public], parameter[featureID]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=[MemberReference(member=BOG__OEG_NAME, postfix_operators=[], prefix_operators=[], qualifier=AfplibPackage, selectors=[])], statements=[State... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[eUnset] operator[SEP] Keyword[int] identifier[featureID] operator[SEP] {
Keyword[switch] operator[SEP] identifier[featureID] operator[SEP] {
Keyword[case] identifier[AfplibPackage] operator[SEP] identifier[BOG__OEG_NAME] opera... |
public boolean hasPurgeableTombstones(int gcBefore)
{
for (int i = 0; i < size; i++)
{
if (delTimes[i] < gcBefore)
return true;
}
return false;
} | class class_name[name] begin[{]
method[hasPurgeableTombstones, return_type[type[boolean]], modifier[public], parameter[gcBefore]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=delTimes, postfix_operators=[], prefi... | Keyword[public] Keyword[boolean] identifier[hasPurgeableTombstones] operator[SEP] Keyword[int] identifier[gcBefore] operator[SEP] {
Keyword[for] operator[SEP] Keyword[int] identifier[i] operator[=] Other[0] operator[SEP] identifier[i] operator[<] identifier[size] operator[SEP] identifier[i] operator[++] operator... |
public static byte[] encrypt(byte[] data, byte[] key) throws Exception{
//恢复密钥
SecretKey secretKey = new SecretKeySpec(key, "AES");
//Cipher完成加密
Cipher cipher = Cipher.getInstance("AES");
//根据密钥对cipher进行初始化
cipher.init(Cipher.ENCRYPT_MODE, secretKey);
//加密
byte[] encrypt = cipher.doFinal(data);
ret... | class class_name[name] begin[{]
method[encrypt, return_type[type[byte]], modifier[public static], parameter[data, key]] begin[{]
local_variable[type[SecretKey], secretKey]
local_variable[type[Cipher], cipher]
call[cipher.init, parameter[member[Cipher.ENCRYPT_MODE], member[.secre... | Keyword[public] Keyword[static] Keyword[byte] operator[SEP] operator[SEP] identifier[encrypt] operator[SEP] Keyword[byte] operator[SEP] operator[SEP] identifier[data] , Keyword[byte] operator[SEP] operator[SEP] identifier[key] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[SecretKey] identifie... |
private String replacePosixClasses(String input) {
return input
.replace(":alnum:", "\\p{Alnum}")
.replace(":alpha:", "\\p{L}")
.replace(":ascii:", "\\p{ASCII}")
.replace(":digit:", "\\p{Digit}")
.replace(":xdigit:", "\\p{XDigit}");
} | class class_name[name] begin[{]
method[replacePosixClasses, return_type[type[String]], modifier[private], parameter[input]] begin[{]
return[call[input.replace, parameter[literal[":alnum:"], literal["\\p{Alnum}"]]]]
end[}]
END[}] | Keyword[private] identifier[String] identifier[replacePosixClasses] operator[SEP] identifier[String] identifier[input] operator[SEP] {
Keyword[return] identifier[input] operator[SEP] identifier[replace] operator[SEP] literal[String] , literal[String] operator[SEP] operator[SEP] identifier[replace] operator[SEP]... |
private String consumeTokenString() throws JsonParserException {
reusableBuffer.setLength(0);
while (true) {
char c = stringChar();
switch (c) {
case '\"':
return reusableBuffer.toString();
case '\\':
int escape = advanceChar();
switch (escape) {
case -1:... | class class_name[name] begin[{]
method[consumeTokenString, return_type[type[String]], modifier[private], parameter[]] begin[{]
call[reusableBuffer.setLength, parameter[literal[0]]]
while[literal[true]] begin[{]
local_variable[type[char], c]
SwitchStatemen... | Keyword[private] identifier[String] identifier[consumeTokenString] operator[SEP] operator[SEP] Keyword[throws] identifier[JsonParserException] {
identifier[reusableBuffer] operator[SEP] identifier[setLength] operator[SEP] Other[0] operator[SEP] operator[SEP] Keyword[while] operator[SEP] literal[boolean] operator... |
public void removeGroupFromPathProfile(int group_id, int pathId, int profileId) {
int[] groupIds = Utils.arrayFromStringOfIntegers(getGroupIdsInPathProfile(profileId,
pathId));
String newGroupIds = "";
for (int i =... | class class_name[name] begin[{]
method[removeGroupFromPathProfile, return_type[void], modifier[public], parameter[group_id, pathId, profileId]] begin[{]
local_variable[type[int], groupIds]
local_variable[type[String], newGroupIds]
ForStatement(body=BlockStatement(label=None, statements=... | Keyword[public] Keyword[void] identifier[removeGroupFromPathProfile] operator[SEP] Keyword[int] identifier[group_id] , Keyword[int] identifier[pathId] , Keyword[int] identifier[profileId] operator[SEP] {
Keyword[int] operator[SEP] operator[SEP] identifier[groupIds] operator[=] identifier[Utils] operator[SEP] i... |
private boolean doAcquireNanos(long arg, long nanosTimeout)
throws InterruptedException {
if (nanosTimeout <= 0L)
return false;
final long deadline = System.nanoTime() + nanosTimeout;
final Node node = addWaiter(Node.EXCLUSIVE);
try {
for (;;) {
... | class class_name[name] begin[{]
method[doAcquireNanos, return_type[type[boolean]], modifier[private], parameter[arg, nanosTimeout]] begin[{]
if[binary_operation[member[.nanosTimeout], <=, literal[0L]]] begin[{]
return[literal[false]]
else begin[{]
None
end[}]
local_varia... | Keyword[private] Keyword[boolean] identifier[doAcquireNanos] operator[SEP] Keyword[long] identifier[arg] , Keyword[long] identifier[nanosTimeout] operator[SEP] Keyword[throws] identifier[InterruptedException] {
Keyword[if] operator[SEP] identifier[nanosTimeout] operator[<=] Other[0L] operator[SEP] Keyword[retur... |
@Override
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
... | class class_name[name] begin[{]
method[deploy, return_type[void], modifier[public], parameter[phaseContext]] begin[{]
local_variable[type[DeploymentUnit], deploymentUnit]
local_variable[type[ModuleSpecification], moduleSpecification]
local_variable[type[ModuleLoader], moduleLoader]
... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[deploy] operator[SEP] identifier[DeploymentPhaseContext] identifier[phaseContext] operator[SEP] Keyword[throws] identifier[DeploymentUnitProcessingException] {
Keyword[final] identifier[DeploymentUnit] identifier[deploymentUnit] operator... |
public GetShippingLabelRequest withJobIds(String... jobIds) {
if (this.jobIds == null) {
setJobIds(new com.amazonaws.internal.SdkInternalList<String>(jobIds.length));
}
for (String ele : jobIds) {
this.jobIds.add(ele);
}
return this;
} | class class_name[name] begin[{]
method[withJobIds, return_type[type[GetShippingLabelRequest]], modifier[public], parameter[jobIds]] begin[{]
if[binary_operation[THIS[member[None.jobIds]], ==, literal[null]]] begin[{]
call[.setJobIds, parameter[ClassCreator(arguments=[Mem... | Keyword[public] identifier[GetShippingLabelRequest] identifier[withJobIds] operator[SEP] identifier[String] operator[...] identifier[jobIds] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[jobIds] operator[==] Other[null] operator[SEP] {
identifier[setJobIds] operator[... |
public static ExtendedTransactionManager getClientTransactionManager() {
if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
Tr.entry(tc, "getClientTransactionManager");
if (_tranManager == null) {
loadEmbeddableTranManager(clientTMKey);
}
if (Trace... | class class_name[name] begin[{]
method[getClientTransactionManager, return_type[type[ExtendedTransactionManager]], modifier[public static], parameter[]] begin[{]
if[binary_operation[call[TraceComponent.isAnyTracingEnabled, parameter[]], &&, call[tc.isEntryEnabled, parameter[]]]] begin[{]
... | Keyword[public] Keyword[static] identifier[ExtendedTransactionManager] identifier[getClientTransactionManager] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[TraceComponent] operator[SEP] identifier[isAnyTracingEnabled] operator[SEP] operator[SEP] operator[&&] identifier[tc] operator[SEP] ide... |
private HttpResponse executeGet(String bucketName, String objectName, Map<String,String> headerMap,
Map<String,String> queryParamMap)
throws InvalidBucketNameException, NoSuchAlgorithmException, InsufficientDataException, IOException,
InvalidKeyException, NoResponseExcep... | class class_name[name] begin[{]
method[executeGet, return_type[type[HttpResponse]], modifier[private], parameter[bucketName, objectName, headerMap, queryParamMap]] begin[{]
return[call[.execute, parameter[member[Method.GET], call[.getRegion, parameter[member[.bucketName]]], member[.bucketName], member[... | Keyword[private] identifier[HttpResponse] identifier[executeGet] operator[SEP] identifier[String] identifier[bucketName] , identifier[String] identifier[objectName] , identifier[Map] operator[<] identifier[String] , identifier[String] operator[>] identifier[headerMap] , identifier[Map] operator[<] identifier[String... |
public Attributes put(Attribute attribute) {
Validate.notNull(attribute);
put(attribute.getKey(), attribute.getValue());
attribute.parent = this;
return this;
} | class class_name[name] begin[{]
method[put, return_type[type[Attributes]], modifier[public], parameter[attribute]] begin[{]
call[Validate.notNull, parameter[member[.attribute]]]
call[.put, parameter[call[attribute.getKey, parameter[]], call[attribute.getValue, parameter[]]]]
... | Keyword[public] identifier[Attributes] identifier[put] operator[SEP] identifier[Attribute] identifier[attribute] operator[SEP] {
identifier[Validate] operator[SEP] identifier[notNull] operator[SEP] identifier[attribute] operator[SEP] operator[SEP] identifier[put] operator[SEP] identifier[attribute] operator[SEP]... |
public byte[] sendOutbind(OutputStream os, int sequenceNumber, String systemId, String password)
throws PDUStringException, IOException
{
byte[] b = this.pduComposer.outbind( sequenceNumber,systemId, password);
writeAndFlush(os, b);
return b;
} | class class_name[name] begin[{]
method[sendOutbind, return_type[type[byte]], modifier[public], parameter[os, sequenceNumber, systemId, password]] begin[{]
local_variable[type[byte], b]
call[.writeAndFlush, parameter[member[.os], member[.b]]]
return[member[.b]]
end[}]
END[}] | Keyword[public] Keyword[byte] operator[SEP] operator[SEP] identifier[sendOutbind] operator[SEP] identifier[OutputStream] identifier[os] , Keyword[int] identifier[sequenceNumber] , identifier[String] identifier[systemId] , identifier[String] identifier[password] operator[SEP] Keyword[throws] identifier[PDUStringExcep... |
public static ResourceUtils getResourceUtils() {
if (resourceUtils == null) {
try {
Class clazz = Class.forName(RESOURCE_UTILS);
resourceUtils = (ResourceUtils) clazz.newInstance();
} catch (ClassNotFoundException | InstantiationException | IllegalAccessException e) {
LOGGER.warn... | class class_name[name] begin[{]
method[getResourceUtils, return_type[type[ResourceUtils]], modifier[public static], parameter[]] begin[{]
if[binary_operation[member[.resourceUtils], ==, literal[null]]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators... | Keyword[public] Keyword[static] identifier[ResourceUtils] identifier[getResourceUtils] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[resourceUtils] operator[==] Other[null] operator[SEP] {
Keyword[try] {
identifier[Class] identifier[clazz] operator[=] identifier[Cla... |
@CheckForNull
public static SCMDecisionHandler firstShouldPollVeto(@Nonnull Item item) {
for (SCMDecisionHandler handler : all()) {
if (!handler.shouldPoll(item)) {
return handler;
}
}
return null;
} | class class_name[name] begin[{]
method[firstShouldPollVeto, return_type[type[SCMDecisionHandler]], modifier[public static], parameter[item]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=item, postfix_operators... | annotation[@] identifier[CheckForNull] Keyword[public] Keyword[static] identifier[SCMDecisionHandler] identifier[firstShouldPollVeto] operator[SEP] annotation[@] identifier[Nonnull] identifier[Item] identifier[item] operator[SEP] {
Keyword[for] operator[SEP] identifier[SCMDecisionHandler] identifier[handler] ope... |
public I buildInvocation(Object protocolKey, I invocation)
throws ConfigException
{
Objects.requireNonNull(invocation);
invocation = buildInvocation(invocation);
// XXX: see if can remove this, and rely on the invocation cache existing
LruCache<Object,I> invocationCache = _invocationCache;
... | class class_name[name] begin[{]
method[buildInvocation, return_type[type[I]], modifier[public], parameter[protocolKey, invocation]] begin[{]
call[Objects.requireNonNull, parameter[member[.invocation]]]
assign[member[.invocation], call[.buildInvocation, parameter[member[.invocati... | Keyword[public] identifier[I] identifier[buildInvocation] operator[SEP] identifier[Object] identifier[protocolKey] , identifier[I] identifier[invocation] operator[SEP] Keyword[throws] identifier[ConfigException] {
identifier[Objects] operator[SEP] identifier[requireNonNull] operator[SEP] identifier[invocation] ... |
@Override
String[] executeCommand(int timeout, String componentName, Object... data) {
mComponentsMap = new HashMap<>();
Window[] displayableWindows = getDisplayableWindows();
for (Window window : displayableWindows) {
if (window.getName() != null) {
addToMap(win... | class class_name[name] begin[{]
method[executeCommand, return_type[type[String]], modifier[default], parameter[timeout, componentName, data]] begin[{]
assign[member[.mComponentsMap], ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[]... | annotation[@] identifier[Override] identifier[String] operator[SEP] operator[SEP] identifier[executeCommand] operator[SEP] Keyword[int] identifier[timeout] , identifier[String] identifier[componentName] , identifier[Object] operator[...] identifier[data] operator[SEP] {
identifier[mComponentsMap] operator[=] K... |
public void serviceAvailable(BeanContextServiceAvailableEvent event)
{
if (null == event)
{
throw new NullPointerException(Messages.getString("beans.1C")); //$NON-NLS-1$
}
if (services.containsKey(event.serviceClass))
{
return;
}
fireServiceAdded(event);
Object childs[] = copyChildren();
for (i... | class class_name[name] begin[{]
method[serviceAvailable, return_type[void], modifier[public], parameter[event]] begin[{]
if[binary_operation[literal[null], ==, member[.event]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[MethodInvocation(arguments=[Literal(postfix_ope... | Keyword[public] Keyword[void] identifier[serviceAvailable] operator[SEP] identifier[BeanContextServiceAvailableEvent] identifier[event] operator[SEP] {
Keyword[if] operator[SEP] Other[null] operator[==] identifier[event] operator[SEP] {
Keyword[throw] Keyword[new] identifier[NullPointerException] oper... |
public static String toListString(Collection self, int maxSize) {
return (self == null) ? "null" : InvokerHelper.toListString(self, maxSize);
} | class class_name[name] begin[{]
method[toListString, return_type[type[String]], modifier[public static], parameter[self, maxSize]] begin[{]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=self, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), oper... | Keyword[public] Keyword[static] identifier[String] identifier[toListString] operator[SEP] identifier[Collection] identifier[self] , Keyword[int] identifier[maxSize] operator[SEP] {
Keyword[return] operator[SEP] identifier[self] operator[==] Other[null] operator[SEP] operator[?] literal[String] operator[:] iden... |
public String put(String group, String key, String value) {
return this.groupedMap.put(group, key, value);
} | class class_name[name] begin[{]
method[put, return_type[type[String]], modifier[public], parameter[group, key, value]] begin[{]
return[THIS[member[None.groupedMap]call[None.put, parameter[member[.group], member[.key], member[.value]]]]]
end[}]
END[}] | Keyword[public] identifier[String] identifier[put] operator[SEP] identifier[String] identifier[group] , identifier[String] identifier[key] , identifier[String] identifier[value] operator[SEP] {
Keyword[return] Keyword[this] operator[SEP] identifier[groupedMap] operator[SEP] identifier[put] operator[SEP] identi... |
private IdentifierToken eatIdOrKeywordAsId() {
Token token = nextToken();
if (token.type == TokenType.IDENTIFIER) {
return (IdentifierToken) token;
} else if (Keywords.isKeyword(token.type)) {
return new IdentifierToken(
token.location, Keywords.get(token.type).toString());
} else ... | class class_name[name] begin[{]
method[eatIdOrKeywordAsId, return_type[type[IdentifierToken]], modifier[private], parameter[]] begin[{]
local_variable[type[Token], token]
if[binary_operation[member[token.type], ==, member[TokenType.IDENTIFIER]]] begin[{]
return[Cast(expressi... | Keyword[private] identifier[IdentifierToken] identifier[eatIdOrKeywordAsId] operator[SEP] operator[SEP] {
identifier[Token] identifier[token] operator[=] identifier[nextToken] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[token] operator[SEP] identifier[type] operator[==] identif... |
public static base_response add(nitro_service client, servicegroup resource) throws Exception {
servicegroup addresource = new servicegroup();
addresource.servicegroupname = resource.servicegroupname;
addresource.servicetype = resource.servicetype;
addresource.cachetype = resource.cachetype;
addresource.td = ... | class class_name[name] begin[{]
method[add, return_type[type[base_response]], modifier[public static], parameter[client, resource]] begin[{]
local_variable[type[servicegroup], addresource]
assign[member[addresource.servicegroupname], member[resource.servicegroupname]]
as... | Keyword[public] Keyword[static] identifier[base_response] identifier[add] operator[SEP] identifier[nitro_service] identifier[client] , identifier[servicegroup] identifier[resource] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[servicegroup] identifier[addresource] operator[=] Keyword[new] ide... |
public BaseFontParameters getBaseFontParameters(String name) {
String alias = (String)aliases.get(name);
if (alias == null)
return (BaseFontParameters)mapper.get(name);
BaseFontParameters p = (BaseFontParameters)mapper.get(alias);
if (p == null)
return (BaseFontPa... | class class_name[name] begin[{]
method[getBaseFontParameters, return_type[type[BaseFontParameters]], modifier[public], parameter[name]] begin[{]
local_variable[type[String], alias]
if[binary_operation[member[.alias], ==, literal[null]]] begin[{]
return[Cast(expression=MethodInvocation(a... | Keyword[public] identifier[BaseFontParameters] identifier[getBaseFontParameters] operator[SEP] identifier[String] identifier[name] operator[SEP] {
identifier[String] identifier[alias] operator[=] operator[SEP] identifier[String] operator[SEP] identifier[aliases] operator[SEP] identifier[get] operator[SEP] identi... |
public ServiceFuture<List<CloudJobSchedule>> listAsync(final ListOperationCallback<CloudJobSchedule> serviceCallback) {
return AzureServiceFuture.fromHeaderPageResponse(
listSinglePageAsync(),
new Func1<String, Observable<ServiceResponseWithHeaders<Page<CloudJobSchedule>, JobScheduleList... | class class_name[name] begin[{]
method[listAsync, return_type[type[ServiceFuture]], modifier[public], parameter[serviceCallback]] begin[{]
return[call[AzureServiceFuture.fromHeaderPageResponse, parameter[call[.listSinglePageAsync, parameter[]], ClassCreator(arguments=[], body=[MethodDeclaration(annotat... | Keyword[public] identifier[ServiceFuture] operator[<] identifier[List] operator[<] identifier[CloudJobSchedule] operator[>] operator[>] identifier[listAsync] operator[SEP] Keyword[final] identifier[ListOperationCallback] operator[<] identifier[CloudJobSchedule] operator[>] identifier[serviceCallback] operator[SEP] {
... |
public Set<Role> getRolesFromDB(final JAASSystem _jaasSystem)
throws EFapsException
{
final Set<Role> ret = new HashSet<>();
Connection con = null;
try {
final List<Long> roleIds = new ArrayList<>();
con = Context.getConnection();
PreparedStatemen... | class class_name[name] begin[{]
method[getRolesFromDB, return_type[type[Set]], modifier[public], parameter[_jaasSystem]] begin[{]
local_variable[type[Set], ret]
local_variable[type[Connection], con]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclar... | Keyword[public] identifier[Set] operator[<] identifier[Role] operator[>] identifier[getRolesFromDB] operator[SEP] Keyword[final] identifier[JAASSystem] identifier[_jaasSystem] operator[SEP] Keyword[throws] identifier[EFapsException] {
Keyword[final] identifier[Set] operator[<] identifier[Role] operator[>] identi... |
public static int generateViewId(){
for (;;) {
final int result = nextGeneratedViewId.get();
// aapt-generated IDs have the high byte nonzero; clamp to the range under that.
int newValue = result + 1;
if (newValue > 0x00FFFFFF) newValue = 1; // Roll over to 1, not... | class class_name[name] begin[{]
method[generateViewId, return_type[type[int]], modifier[public static], parameter[]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MethodInvocation(arg... | Keyword[public] Keyword[static] Keyword[int] identifier[generateViewId] operator[SEP] operator[SEP] {
Keyword[for] operator[SEP] operator[SEP] operator[SEP] operator[SEP] {
Keyword[final] Keyword[int] identifier[result] operator[=] identifier[nextGeneratedViewId] operator[SEP] identifier[get] operator... |
public static JMXConnector connect(final String hostportOrPid, final String login, final String password)
throws IOException {
// ./vjmxcli.sh - 127.0.0.1:8060 gcutil
if (hostportOrPid.contains(":")) {
JMXServiceURL rmiurl = new JMXServiceURL(
"service:jmx:rmi://" + hostportOrPid + "/jndi/rmi://" + hostp... | class class_name[name] begin[{]
method[connect, return_type[type[JMXConnector]], modifier[public static], parameter[hostportOrPid, login, password]] begin[{]
if[call[hostportOrPid.contains, parameter[literal[":"]]]] begin[{]
local_variable[type[JMXServiceURL], rmiurl]
re... | Keyword[public] Keyword[static] identifier[JMXConnector] identifier[connect] operator[SEP] Keyword[final] identifier[String] identifier[hostportOrPid] , Keyword[final] identifier[String] identifier[login] , Keyword[final] identifier[String] identifier[password] operator[SEP] Keyword[throws] identifier[IOException] {... |
public void setEntities(FSArray v) {
if (Document_Type.featOkTst && ((Document_Type)jcasType).casFeat_entities == null)
jcasType.jcas.throwFeatMissing("entities", "de.julielab.jules.types.ace.Document");
jcasType.ll_cas.ll_setRefValue(addr, ((Document_Type)jcasType).casFeatCode_entities, jcasType.ll_cas.l... | class class_name[name] begin[{]
method[setEntities, return_type[void], modifier[public], parameter[v]] begin[{]
if[binary_operation[member[Document_Type.featOkTst], &&, binary_operation[Cast(expression=MemberReference(member=jcasType, postfix_operators=[], prefix_operators=[], qualifier=, selec... | Keyword[public] Keyword[void] identifier[setEntities] operator[SEP] identifier[FSArray] identifier[v] operator[SEP] {
Keyword[if] operator[SEP] identifier[Document_Type] operator[SEP] identifier[featOkTst] operator[&&] operator[SEP] operator[SEP] identifier[Document_Type] operator[SEP] identifier[jcasType] opera... |
public <T> T read(String json, Class<T> expectedReturnType) {
try {
ObjectMapper objectMapper = new ObjectMapper();
JsonNode tree = objectMapper.readTree(json);
return read(tree, expectedReturnType);
} catch (IOException e) {
throw new InvalidJsonException... | class class_name[name] begin[{]
method[read, return_type[type[T]], modifier[public], parameter[json, expectedReturnType]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=ClassCreator(arguments=[], body=None, constructor_ty... | Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[read] operator[SEP] identifier[String] identifier[json] , identifier[Class] operator[<] identifier[T] operator[>] identifier[expectedReturnType] operator[SEP] {
Keyword[try] {
identifier[ObjectMapper] identifier[objectMapp... |
private boolean getBooleanAttributeValue(Node source) {
Attr attribute = (Attr)source;
String value = attribute.getValue();
return "true".equalsIgnoreCase(value);
} | class class_name[name] begin[{]
method[getBooleanAttributeValue, return_type[type[boolean]], modifier[private], parameter[source]] begin[{]
local_variable[type[Attr], attribute]
local_variable[type[String], value]
return[literal["true"]]
end[}]
END[}] | Keyword[private] Keyword[boolean] identifier[getBooleanAttributeValue] operator[SEP] identifier[Node] identifier[source] operator[SEP] {
identifier[Attr] identifier[attribute] operator[=] operator[SEP] identifier[Attr] operator[SEP] identifier[source] operator[SEP] identifier[String] identifier[value] operator[=... |
@Override
public List<CommercePriceList> findByGroupId(long groupId) {
return findByGroupId(groupId, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
} | class class_name[name] begin[{]
method[findByGroupId, return_type[type[List]], modifier[public], parameter[groupId]] begin[{]
return[call[.findByGroupId, parameter[member[.groupId], member[QueryUtil.ALL_POS], member[QueryUtil.ALL_POS], literal[null]]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] identifier[List] operator[<] identifier[CommercePriceList] operator[>] identifier[findByGroupId] operator[SEP] Keyword[long] identifier[groupId] operator[SEP] {
Keyword[return] identifier[findByGroupId] operator[SEP] identifier[groupId] , identifier[QueryUtil] ... |
private static org.tinylog.Level translateLevel(final Level level) {
switch (level) {
case TRACE:
return org.tinylog.Level.TRACE;
case DEBUG:
return org.tinylog.Level.DEBUG;
case INFO:
return org.tinylog.Level.INFO;
case WARN:
return org.tinylog.Level.WARN;
case ERROR:
case FATAL:
... | class class_name[name] begin[{]
method[translateLevel, return_type[type[org]], modifier[private static], parameter[level]] begin[{]
SwitchStatement(cases=[SwitchStatementCase(case=['TRACE'], statements=[ReturnStatement(expression=MemberReference(member=TRACE, postfix_operators=[], prefix_operators=[], ... | Keyword[private] Keyword[static] identifier[org] operator[SEP] identifier[tinylog] operator[SEP] identifier[Level] identifier[translateLevel] operator[SEP] Keyword[final] identifier[Level] identifier[level] operator[SEP] {
Keyword[switch] operator[SEP] identifier[level] operator[SEP] {
Keyword[case] i... |
@Override
public StopFlowResult stopFlow(StopFlowRequest request) {
request = beforeClientExecution(request);
return executeStopFlow(request);
} | class class_name[name] begin[{]
method[stopFlow, return_type[type[StopFlowResult]], modifier[public], parameter[request]] begin[{]
assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]]
return[call[.executeStopFlow, parameter[member[.request]]]]
end[}]
E... | annotation[@] identifier[Override] Keyword[public] identifier[StopFlowResult] identifier[stopFlow] operator[SEP] identifier[StopFlowRequest] identifier[request] operator[SEP] {
identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] identifier[request] operator[SEP] operator[SEP] Keyword[... |
public String formatDuration(Duration duration)
{
if (duration == null)
return format(now());
TimeFormat timeFormat = getFormat(duration.getUnit());
return timeFormat.format(duration);
} | class class_name[name] begin[{]
method[formatDuration, return_type[type[String]], modifier[public], parameter[duration]] begin[{]
if[binary_operation[member[.duration], ==, literal[null]]] begin[{]
return[call[.format, parameter[call[.now, parameter[]]]]]
else begin[{]
None
end[... | Keyword[public] identifier[String] identifier[formatDuration] operator[SEP] identifier[Duration] identifier[duration] operator[SEP] {
Keyword[if] operator[SEP] identifier[duration] operator[==] Other[null] operator[SEP] Keyword[return] identifier[format] operator[SEP] identifier[now] operator[SEP] operator[SEP] ... |
@Override
public void uploadChunk(String location, ByteBuffer chunk) throws TException {
TimeCacheMap<Object, Object> uploaders = data.getUploaders();
Object obj = uploaders.get(location);
if (obj == null) {
throw new TException("File for that location does not exist (or timed ou... | class class_name[name] begin[{]
method[uploadChunk, return_type[void], modifier[public], parameter[location, chunk]] begin[{]
local_variable[type[TimeCacheMap], uploaders]
local_variable[type[Object], obj]
if[binary_operation[member[.obj], ==, literal[null]]] begin[{]
... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[uploadChunk] operator[SEP] identifier[String] identifier[location] , identifier[ByteBuffer] identifier[chunk] operator[SEP] Keyword[throws] identifier[TException] {
identifier[TimeCacheMap] operator[<] identifier[Object] , identifier[O... |
public Rectangle getViewport() {
@SuppressWarnings("unchecked")
Map<String, Number> result = (Map<String, Number>) executeScript(JS_GET_VIEWPORT);
int width = result.get("width").intValue();
int height = result.get("height").intValue();
Rectangle viewport = new Rectangle(0, 0, height, width, width, height);
... | class class_name[name] begin[{]
method[getViewport, return_type[type[Rectangle]], modifier[public], parameter[]] begin[{]
local_variable[type[Map], result]
local_variable[type[int], width]
local_variable[type[int], height]
local_variable[type[Rectangle], viewport]
... | Keyword[public] identifier[Rectangle] identifier[getViewport] operator[SEP] operator[SEP] {
annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[Number] operator[>] identifier[result] operator[=] operator[SEP] identifi... |
public static CPDefinitionOptionValueRel[] findByCompanyId_PrevAndNext(
long CPDefinitionOptionValueRelId, long companyId,
OrderByComparator<CPDefinitionOptionValueRel> orderByComparator)
throws com.liferay.commerce.product.exception.NoSuchCPDefinitionOptionValueRelException {
return getPersistence()
.fi... | class class_name[name] begin[{]
method[findByCompanyId_PrevAndNext, return_type[type[CPDefinitionOptionValueRel]], modifier[public static], parameter[CPDefinitionOptionValueRelId, companyId, orderByComparator]] begin[{]
return[call[.getPersistence, parameter[]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[CPDefinitionOptionValueRel] operator[SEP] operator[SEP] identifier[findByCompanyId_PrevAndNext] operator[SEP] Keyword[long] identifier[CPDefinitionOptionValueRelId] , Keyword[long] identifier[companyId] , identifier[OrderByComparator] operator[<] identifier[CPDefinitionOptio... |
public License getLicense(final DbLicense dbLicense) {
final License license = DataModelFactory.createLicense(dbLicense.getName(), dbLicense.getLongName(),
dbLicense.getComments(), dbLicense.getRegexp(), dbLicense.getUrl());
if (dbLicense.isApproved() != null) {
license.setAppro... | class class_name[name] begin[{]
method[getLicense, return_type[type[License]], modifier[public], parameter[dbLicense]] begin[{]
local_variable[type[License], license]
if[binary_operation[call[dbLicense.isApproved, parameter[]], !=, literal[null]]] begin[{]
call[l... | Keyword[public] identifier[License] identifier[getLicense] operator[SEP] Keyword[final] identifier[DbLicense] identifier[dbLicense] operator[SEP] {
Keyword[final] identifier[License] identifier[license] operator[=] identifier[DataModelFactory] operator[SEP] identifier[createLicense] operator[SEP] identifier[dbLi... |
private static void seedData(PersistenceManager manager) throws OnyxException
{
Account account = new Account();
//noinspection SpellCheckingInspection
account.setAccountName("Timbob's Lawn Care");
account.setBalanceDue(55.43f);
Invoice marchLawnInvoice = new Invoice();
... | class class_name[name] begin[{]
method[seedData, return_type[void], modifier[private static], parameter[manager]] begin[{]
local_variable[type[Account], account]
call[account.setAccountName, parameter[literal["Timbob's Lawn Care"]]]
call[account.setBalanceDue, parameter[... | Keyword[private] Keyword[static] Keyword[void] identifier[seedData] operator[SEP] identifier[PersistenceManager] identifier[manager] operator[SEP] Keyword[throws] identifier[OnyxException] {
identifier[Account] identifier[account] operator[=] Keyword[new] identifier[Account] operator[SEP] operator[SEP] operator[... |
public <T> JavaRDD<T> createJavaRDD(
ExtractorConfig<T> config) {
return new DeepJavaRDD<>((DeepRDD<T, ExtractorConfig<T>>) createRDD(config));
} | class class_name[name] begin[{]
method[createJavaRDD, return_type[type[JavaRDD]], modifier[public], parameter[config]] begin[{]
return[ClassCreator(arguments=[Cast(expression=MethodInvocation(arguments=[MemberReference(member=config, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])]... | Keyword[public] operator[<] identifier[T] operator[>] identifier[JavaRDD] operator[<] identifier[T] operator[>] identifier[createJavaRDD] operator[SEP] identifier[ExtractorConfig] operator[<] identifier[T] operator[>] identifier[config] operator[SEP] {
Keyword[return] Keyword[new] identifier[DeepJavaRDD] operato... |
private Expression compileDefaultMessagePartsConstant(MsgPartsAndIds partsAndId) {
return variables
.addStaticField("msg_parts_" + partsAndId.id, partsToPartsList(partsAndId.parts))
.accessor();
} | class class_name[name] begin[{]
method[compileDefaultMessagePartsConstant, return_type[type[Expression]], modifier[private], parameter[partsAndId]] begin[{]
return[call[variables.addStaticField, parameter[binary_operation[literal["msg_parts_"], +, member[partsAndId.id]], call[.partsToPartsList, paramet... | Keyword[private] identifier[Expression] identifier[compileDefaultMessagePartsConstant] operator[SEP] identifier[MsgPartsAndIds] identifier[partsAndId] operator[SEP] {
Keyword[return] identifier[variables] operator[SEP] identifier[addStaticField] operator[SEP] literal[String] operator[+] identifier[partsAndId] op... |
public static Rule createDefaultPolygonRule() {
PolygonSymbolizer polygonSymbolizer = sf.createPolygonSymbolizer();
Fill fill = createDefaultFill();
polygonSymbolizer.setFill(fill);
polygonSymbolizer.setStroke(createDefaultStroke());
Rule rule = sf.createRule();
rule.set... | class class_name[name] begin[{]
method[createDefaultPolygonRule, return_type[type[Rule]], modifier[public static], parameter[]] begin[{]
local_variable[type[PolygonSymbolizer], polygonSymbolizer]
local_variable[type[Fill], fill]
call[polygonSymbolizer.setFill, parameter[member[.... | Keyword[public] Keyword[static] identifier[Rule] identifier[createDefaultPolygonRule] operator[SEP] operator[SEP] {
identifier[PolygonSymbolizer] identifier[polygonSymbolizer] operator[=] identifier[sf] operator[SEP] identifier[createPolygonSymbolizer] operator[SEP] operator[SEP] operator[SEP] identifier[Fill] i... |
public void clickOnViewDirect(View V)
{
final View viewToClick = V;
viewToClick.post(new Runnable() {
@Override
public void run() {
viewToClick.performClick();
}
}
);
} | class class_name[name] begin[{]
method[clickOnViewDirect, return_type[void], modifier[public], parameter[V]] begin[{]
local_variable[type[View], viewToClick]
call[viewToClick.post, parameter[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Ov... | Keyword[public] Keyword[void] identifier[clickOnViewDirect] operator[SEP] identifier[View] identifier[V] operator[SEP] {
Keyword[final] identifier[View] identifier[viewToClick] operator[=] identifier[V] operator[SEP] identifier[viewToClick] operator[SEP] identifier[post] operator[SEP] Keyword[new] identifier[Run... |
public static boolean isSuperSenseFeatures(final TrainingParameters params) {
final String mfsFeatures = getSuperSenseFeatures(params);
return !mfsFeatures.equalsIgnoreCase(Flags.DEFAULT_FEATURE_FLAG);
} | class class_name[name] begin[{]
method[isSuperSenseFeatures, return_type[type[boolean]], modifier[public static], parameter[params]] begin[{]
local_variable[type[String], mfsFeatures]
return[call[mfsFeatures.equalsIgnoreCase, parameter[member[Flags.DEFAULT_FEATURE_FLAG]]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[boolean] identifier[isSuperSenseFeatures] operator[SEP] Keyword[final] identifier[TrainingParameters] identifier[params] operator[SEP] {
Keyword[final] identifier[String] identifier[mfsFeatures] operator[=] identifier[getSuperSenseFeatures] operator[SEP] identifier[params]... |
public <E> E load(Class<E> entityClass, DatastoreKey parentKey, long id) {
EntityMetadata entityMetadata = EntityIntrospector.introspect(entityClass);
Key nativeKey;
if (parentKey == null) {
nativeKey = entityManager.newNativeKeyFactory().setKind(entityMetadata.getKind()).newKey(id);
} else {
... | class class_name[name] begin[{]
method[load, return_type[type[E]], modifier[public], parameter[entityClass, parentKey, id]] begin[{]
local_variable[type[EntityMetadata], entityMetadata]
local_variable[type[Key], nativeKey]
if[binary_operation[member[.parentKey], ==, literal[null... | Keyword[public] operator[<] identifier[E] operator[>] identifier[E] identifier[load] operator[SEP] identifier[Class] operator[<] identifier[E] operator[>] identifier[entityClass] , identifier[DatastoreKey] identifier[parentKey] , Keyword[long] identifier[id] operator[SEP] {
identifier[EntityMetadata] identifie... |
public static <F extends Future<Void>> Mono<Void> deferFutureWithContext(Function<Context, F> deferredFuture) {
return new DeferredContextFutureMono<>(deferredFuture);
} | class class_name[name] begin[{]
method[deferFutureWithContext, return_type[type[Mono]], modifier[public static], parameter[deferredFuture]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=deferredFuture, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], body=None, co... | Keyword[public] Keyword[static] operator[<] identifier[F] Keyword[extends] identifier[Future] operator[<] identifier[Void] operator[>] operator[>] identifier[Mono] operator[<] identifier[Void] operator[>] identifier[deferFutureWithContext] operator[SEP] identifier[Function] operator[<] identifier[Context] , identifier... |
void draw(GLShader shader, InternalTransform xform, int tint,
float dx, float dy, float dw, float dh, float sx, float sy, float sw, float sh) {
float texWidth = width(), texHeight = height();
drawImpl(shader, xform, ensureTexture(), tint, dx, dy, dw, dh,
sx / texWidth, sy / texHeight, (... | class class_name[name] begin[{]
method[draw, return_type[void], modifier[default], parameter[shader, xform, tint, dx, dy, dw, dh, sx, sy, sw, sh]] begin[{]
local_variable[type[float], texWidth]
call[.drawImpl, parameter[member[.shader], member[.xform], call[.ensureTexture, parameter[]],... | Keyword[void] identifier[draw] operator[SEP] identifier[GLShader] identifier[shader] , identifier[InternalTransform] identifier[xform] , Keyword[int] identifier[tint] , Keyword[float] identifier[dx] , Keyword[float] identifier[dy] , Keyword[float] identifier[dw] , Keyword[float] identifier[dh] , Keyword[float] i... |
private void updateLetsEncrypt() {
getReport().println(Messages.get().container(Messages.RPT_STARTING_LETSENCRYPT_UPDATE_0));
CmsLetsEncryptConfiguration config = OpenCms.getLetsEncryptConfig();
if ((config == null) || !config.isValidAndEnabled()) {
return;
}
CmsSit... | class class_name[name] begin[{]
method[updateLetsEncrypt, return_type[void], modifier[private], parameter[]] begin[{]
call[.getReport, parameter[]]
local_variable[type[CmsLetsEncryptConfiguration], config]
if[binary_operation[binary_operation[member[.config], ==, literal... | Keyword[private] Keyword[void] identifier[updateLetsEncrypt] operator[SEP] operator[SEP] {
identifier[getReport] operator[SEP] operator[SEP] operator[SEP] identifier[println] operator[SEP] identifier[Messages] operator[SEP] identifier[get] operator[SEP] operator[SEP] operator[SEP] identifier[container] operator[... |
public void marshall(DescribeDocumentClassificationJobRequest describeDocumentClassificationJobRequest, ProtocolMarshaller protocolMarshaller) {
if (describeDocumentClassificationJobRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[describeDocumentClassificationJobRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.describeDocumentClassificationJobRequest], ==, literal[null]]] begin[{]
ThrowStatement(... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[DescribeDocumentClassificationJobRequest] identifier[describeDocumentClassificationJobRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[describeDocumentClassifi... |
public void setRoundedCorners(final boolean ROUNDED) {
if (null == roundedCorners) {
_roundedCorners = ROUNDED;
fireTileEvent(REDRAW_EVENT);
} else {
roundedCorners.set(ROUNDED);
}
} | class class_name[name] begin[{]
method[setRoundedCorners, return_type[void], modifier[public], parameter[ROUNDED]] begin[{]
if[binary_operation[literal[null], ==, member[.roundedCorners]]] begin[{]
assign[member[._roundedCorners], member[.ROUNDED]]
... | Keyword[public] Keyword[void] identifier[setRoundedCorners] operator[SEP] Keyword[final] Keyword[boolean] identifier[ROUNDED] operator[SEP] {
Keyword[if] operator[SEP] Other[null] operator[==] identifier[roundedCorners] operator[SEP] {
identifier[_roundedCorners] operator[=] identifier[ROUNDED] operat... |
void scan() {
if (acquireScanLock()) {
boolean scheduleRescan = false;
try {
scheduleRescan = scan(false, deploymentOperations);
} finally {
try {
if (scheduleRescan) {
synchronized (this) {
... | class class_name[name] begin[{]
method[scan, return_type[void], modifier[default], parameter[]] begin[{]
if[call[.acquireScanLock, parameter[]]] begin[{]
local_variable[type[boolean], scheduleRescan]
TryStatement(block=[StatementExpression(expression=Assignment(expressio... | Keyword[void] identifier[scan] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[acquireScanLock] operator[SEP] operator[SEP] operator[SEP] {
Keyword[boolean] identifier[scheduleRescan] operator[=] literal[boolean] operator[SEP] Keyword[try] {
identifier[scheduleRescan]... |
public Object convert( String value, TypeLiteral<?> toType )
{
BitSet bitSet = new BitSet();
int currentIndex = 0;
StringTokenizer tokenizer = new StringTokenizer( value, DEFAULT_SEPARATOR );
while ( tokenizer.hasMoreTokens() )
{
String current = tokenizer.nextTo... | class class_name[name] begin[{]
method[convert, return_type[type[Object]], modifier[public], parameter[value, toType]] begin[{]
local_variable[type[BitSet], bitSet]
local_variable[type[int], currentIndex]
local_variable[type[StringTokenizer], tokenizer]
while[call[tokeni... | Keyword[public] identifier[Object] identifier[convert] operator[SEP] identifier[String] identifier[value] , identifier[TypeLiteral] operator[<] operator[?] operator[>] identifier[toType] operator[SEP] {
identifier[BitSet] identifier[bitSet] operator[=] Keyword[new] identifier[BitSet] operator[SEP] operator[SEP]... |
@Deprecated
public List<String> getUsers() {
String value = getParameter(UsernameActivationStrategy.PARAM_USERS);
if (Strings.isNotBlank(value)) {
return Strings.splitAndTrim(value, ",");
}
return Collections.emptyList();
} | class class_name[name] begin[{]
method[getUsers, return_type[type[List]], modifier[public], parameter[]] begin[{]
local_variable[type[String], value]
if[call[Strings.isNotBlank, parameter[member[.value]]]] begin[{]
return[call[Strings.splitAndTrim, parameter[member[.value], ... | annotation[@] identifier[Deprecated] Keyword[public] identifier[List] operator[<] identifier[String] operator[>] identifier[getUsers] operator[SEP] operator[SEP] {
identifier[String] identifier[value] operator[=] identifier[getParameter] operator[SEP] identifier[UsernameActivationStrategy] operator[SEP] identifi... |
@Override
public String getWebInterfaceURL() {
try {
return getWebMonitorBaseUrl().get().toString();
} catch (InterruptedException | ExecutionException e) {
ExceptionUtils.checkInterrupted(e);
log.warn("Could not retrieve the web interface URL for the cluster.", e);
return "Unknown address.";
}
} | class class_name[name] begin[{]
method[getWebInterfaceURL, return_type[type[String]], modifier[public], parameter[]] begin[{]
TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[], member=getWebMonitorBaseUrl, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[Meth... | annotation[@] identifier[Override] Keyword[public] identifier[String] identifier[getWebInterfaceURL] operator[SEP] operator[SEP] {
Keyword[try] {
Keyword[return] identifier[getWebMonitorBaseUrl] operator[SEP] operator[SEP] operator[SEP] identifier[get] operator[SEP] operator[SEP] operator[SEP] identif... |
private void registerOffsetMetrics(
MetricGroup consumerMetricGroup,
List<KafkaTopicPartitionState<KPH>> partitionOffsetStates) {
for (KafkaTopicPartitionState<KPH> ktp : partitionOffsetStates) {
MetricGroup topicPartitionGroup = consumerMetricGroup
.addGroup(OFFSETS_BY_TOPIC_METRICS_GROUP, ktp.getTopic... | class class_name[name] begin[{]
method[registerOffsetMetrics, return_type[void], modifier[private], parameter[consumerMetricGroup, partitionOffsetStates]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimension... | Keyword[private] Keyword[void] identifier[registerOffsetMetrics] operator[SEP] identifier[MetricGroup] identifier[consumerMetricGroup] , identifier[List] operator[<] identifier[KafkaTopicPartitionState] operator[<] identifier[KPH] operator[>] operator[>] identifier[partitionOffsetStates] operator[SEP] {
Keyword... |
public static long getMaxForExtent(PersistenceBroker brokerForClass, FieldDescriptor field) throws PersistenceBrokerException
{
if (field == null)
{
log.error("Given FieldDescriptor was null, could not detect max value across all extents");
return 0;
// thro... | class class_name[name] begin[{]
method[getMaxForExtent, return_type[type[long]], modifier[public static], parameter[brokerForClass, field]] begin[{]
if[binary_operation[member[.field], ==, literal[null]]] begin[{]
call[log.error, parameter[literal["Given FieldDescriptor ... | Keyword[public] Keyword[static] Keyword[long] identifier[getMaxForExtent] operator[SEP] identifier[PersistenceBroker] identifier[brokerForClass] , identifier[FieldDescriptor] identifier[field] operator[SEP] Keyword[throws] identifier[PersistenceBrokerException] {
Keyword[if] operator[SEP] identifier[field] oper... |
@Override
public DBClusterParameterGroup createDBClusterParameterGroup(CreateDBClusterParameterGroupRequest request) {
request = beforeClientExecution(request);
return executeCreateDBClusterParameterGroup(request);
} | class class_name[name] begin[{]
method[createDBClusterParameterGroup, return_type[type[DBClusterParameterGroup]], modifier[public], parameter[request]] begin[{]
assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]]
return[call[.executeCreateDBClusterParamet... | annotation[@] identifier[Override] Keyword[public] identifier[DBClusterParameterGroup] identifier[createDBClusterParameterGroup] operator[SEP] identifier[CreateDBClusterParameterGroupRequest] identifier[request] operator[SEP] {
identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] ident... |
public static String numberTranslator(String target) {
Pattern p = Pattern.compile("[一二两三四五六七八九123456789]万[一二两三四五六七八九123456789](?!(千|百|十))");
Matcher m = p.matcher(target);
StringBuffer sb = new StringBuffer();
boolean result = m.find();
while (result) {
String ... | class class_name[name] begin[{]
method[numberTranslator, return_type[type[String]], modifier[public static], parameter[target]] begin[{]
local_variable[type[Pattern], p]
local_variable[type[Matcher], m]
local_variable[type[StringBuffer], sb]
local_variable[type[boolean], result]... | Keyword[public] Keyword[static] identifier[String] identifier[numberTranslator] operator[SEP] identifier[String] identifier[target] operator[SEP] {
identifier[Pattern] identifier[p] operator[=] identifier[Pattern] operator[SEP] identifier[compile] operator[SEP] literal[String] operator[SEP] operator[SEP] identif... |
private synchronized void writeObject(ObjectOutputStream out) throws IOException {
// todo: for multithreaded usage this block needs to be synchronized
out.defaultWriteObject();
// spec: only write children if not using a peer
if (this.equals(getPeer())) {
writeChildren(out... | class class_name[name] begin[{]
method[writeObject, return_type[void], modifier[synchronized private], parameter[out]] begin[{]
call[out.defaultWriteObject, parameter[]]
if[THIS[call[None.equals, parameter[call[.getPeer, parameter[]]]]]] begin[{]
call[.wr... | Keyword[private] Keyword[synchronized] Keyword[void] identifier[writeObject] operator[SEP] identifier[ObjectOutputStream] identifier[out] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[out] operator[SEP] identifier[defaultWriteObject] operator[SEP] operator[SEP] operator[SEP] Keyword[if] oper... |
public void analyzeForMultiPartitionAccess(Collection<StmtTableScan> scans,
HashMap<AbstractExpression, Set<AbstractExpression>> valueEquivalence) {
//* enable to debug */ System.out.println("DEBUG: analyze4MPAccess w/ scans:" + scans.size() + " filters:" + valueEquivalence.size());
TupleVal... | class class_name[name] begin[{]
method[analyzeForMultiPartitionAccess, return_type[void], modifier[public], parameter[scans, valueEquivalence]] begin[{]
local_variable[type[TupleValueExpression], tokenPartitionKey]
local_variable[type[Set], eqSets]
local_variable[type[int], unfilteredPa... | Keyword[public] Keyword[void] identifier[analyzeForMultiPartitionAccess] operator[SEP] identifier[Collection] operator[<] identifier[StmtTableScan] operator[>] identifier[scans] , identifier[HashMap] operator[<] identifier[AbstractExpression] , identifier[Set] operator[<] identifier[AbstractExpression] operator[>] op... |
public Content getSummaryTableTree(AbstractMemberWriter mw, ClassDoc cd,
List<Content> tableContents, boolean showTabs) {
Content caption;
if (showTabs) {
caption = getTableCaption(mw.methodTypes);
generateMethodTypesScript(mw.typeMap, mw.methodTypes);
}
... | class class_name[name] begin[{]
method[getSummaryTableTree, return_type[type[Content]], modifier[public], parameter[mw, cd, tableContents, showTabs]] begin[{]
local_variable[type[Content], caption]
if[member[.showTabs]] begin[{]
assign[member[.caption], call[.get... | Keyword[public] identifier[Content] identifier[getSummaryTableTree] operator[SEP] identifier[AbstractMemberWriter] identifier[mw] , identifier[ClassDoc] identifier[cd] , identifier[List] operator[<] identifier[Content] operator[>] identifier[tableContents] , Keyword[boolean] identifier[showTabs] operator[SEP] {
... |
public static boolean isProject(Project project, DependencyDescriptor descriptor) {
final String specGAV = String.format("%s:%s:%s", descriptor.getGroup(), descriptor.getName(), descriptor.getVersion());
return getAllProjects(project).containsKey(specGAV) || getIncludedProjectIdentifiers(project).contai... | class class_name[name] begin[{]
method[isProject, return_type[type[boolean]], modifier[public static], parameter[project, descriptor]] begin[{]
local_variable[type[String], specGAV]
return[binary_operation[call[.getAllProjects, parameter[member[.project]]], ||, call[.getIncludedProjectIdentifie... | Keyword[public] Keyword[static] Keyword[boolean] identifier[isProject] operator[SEP] identifier[Project] identifier[project] , identifier[DependencyDescriptor] identifier[descriptor] operator[SEP] {
Keyword[final] identifier[String] identifier[specGAV] operator[=] identifier[String] operator[SEP] identifier[for... |
public final void mESCAPE() throws RecognitionException {
try {
int _type = ESCAPE;
int _channel = DEFAULT_TOKEN_CHANNEL;
// hql.g:25:8: ( 'escape' )
// hql.g:25:10: 'escape'
{
match("escape"); if (state.failed) return;
}
state.type = _type;
state.channel = _channel;
}
finally {
//... | class class_name[name] begin[{]
method[mESCAPE, return_type[void], modifier[final public], parameter[]] begin[{]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(dimensions=[], initializer=MemberReference(member=ESCAPE, postfix_operators=[], prefix_operators=... | Keyword[public] Keyword[final] Keyword[void] identifier[mESCAPE] operator[SEP] operator[SEP] Keyword[throws] identifier[RecognitionException] {
Keyword[try] {
Keyword[int] identifier[_type] operator[=] identifier[ESCAPE] operator[SEP] Keyword[int] identifier[_channel] operator[=] identifier[DEFAULT_TO... |
@Override public void syncCacheToDB(List<Integer> idList) throws IOException {
final SQLiteDatabase database = sqLiteHelper.getWritableDatabase();
database.beginTransaction();
try {
for (Integer id : idList) {
syncCacheToDB(id);
}
database.setT... | class class_name[name] begin[{]
method[syncCacheToDB, return_type[void], modifier[public], parameter[idList]] begin[{]
local_variable[type[SQLiteDatabase], database]
call[database.beginTransaction, parameter[]]
TryStatement(block=[ForStatement(body=BlockStatement(label=None, sta... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[syncCacheToDB] operator[SEP] identifier[List] operator[<] identifier[Integer] operator[>] identifier[idList] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[final] identifier[SQLiteDatabase] identifier[database] operator[... |
void unregisterQueryWatcher(@NotNull ApolloQueryWatcher queryWatcher) {
checkNotNull(queryWatcher, "queryWatcher == null");
OperationName operationName = queryWatcher.operation().name();
unregisterCall(activeQueryWatchers, operationName, queryWatcher);
} | class class_name[name] begin[{]
method[unregisterQueryWatcher, return_type[void], modifier[default], parameter[queryWatcher]] begin[{]
call[.checkNotNull, parameter[member[.queryWatcher], literal["queryWatcher == null"]]]
local_variable[type[OperationName], operationName]
... | Keyword[void] identifier[unregisterQueryWatcher] operator[SEP] annotation[@] identifier[NotNull] identifier[ApolloQueryWatcher] identifier[queryWatcher] operator[SEP] {
identifier[checkNotNull] operator[SEP] identifier[queryWatcher] , literal[String] operator[SEP] operator[SEP] identifier[OperationName] identif... |
public void cleanExpiredCallbacks() {
long now = System.currentTimeMillis();
// Cuncurrency could be possible for multiple instantiations
synchronized(regCallbacks) {
Iterator<Map.Entry<String, RegisteredCallback>> it = regCallbacks.entrySet().iterator();
Map... | class class_name[name] begin[{]
method[cleanExpiredCallbacks, return_type[void], modifier[public], parameter[]] begin[{]
local_variable[type[long], now]
SYNCHRONIZED[member[.regCallbacks]] BEGIN[{]
local_variable[type[Iterator], it]
local_variable[type[Map], entr... | Keyword[public] Keyword[void] identifier[cleanExpiredCallbacks] operator[SEP] operator[SEP] {
Keyword[long] identifier[now] operator[=] identifier[System] operator[SEP] identifier[currentTimeMillis] operator[SEP] operator[SEP] operator[SEP] Keyword[synchronized] operator[SEP] identifier[regCallbacks] operator[SE... |
public Optional<CoreNLPParseNode> nodeForOffsets(
final OffsetRange<CharOffset> offsets) {
// we use the reverse of the preorder traversal because it will iterate over smaller nodes
// before any of their parents, preferring the smallest node that contains these offsets.
for (final CoreNLPParseNode n ... | class class_name[name] begin[{]
method[nodeForOffsets, return_type[type[Optional]], modifier[public], parameter[offsets]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MethodInvocation(arguments=[], member=span, postfix_operators=[], pr... | Keyword[public] identifier[Optional] operator[<] identifier[CoreNLPParseNode] operator[>] identifier[nodeForOffsets] operator[SEP] Keyword[final] identifier[OffsetRange] operator[<] identifier[CharOffset] operator[>] identifier[offsets] operator[SEP] {
Keyword[for] operator[SEP] Keyword[final] identifier[CoreNLP... |
public Observable<Void> deleteByScopeAsync(String scope, String lockName) {
return deleteByScopeWithServiceResponseAsync(scope, lockName).map(new Func1<ServiceResponse<Void>, Void>() {
@Override
public Void call(ServiceResponse<Void> response) {
return response.body();
... | class class_name[name] begin[{]
method[deleteByScopeAsync, return_type[type[Observable]], modifier[public], parameter[scope, lockName]] begin[{]
return[call[.deleteByScopeWithServiceResponseAsync, parameter[member[.scope], member[.lockName]]]]
end[}]
END[}] | Keyword[public] identifier[Observable] operator[<] identifier[Void] operator[>] identifier[deleteByScopeAsync] operator[SEP] identifier[String] identifier[scope] , identifier[String] identifier[lockName] operator[SEP] {
Keyword[return] identifier[deleteByScopeWithServiceResponseAsync] operator[SEP] identifier[s... |
private void writeInterface(final GeneratorContext context, final TreeLogger logger,
final BeanHelper bean) {
final PrintWriter pw = context.tryCreate(logger, bean.getPackage(), bean.getValidatorName());
if (pw != null) {
final TreeLogger interfaceLogger = logger.branch(TreeLogger.TRACE,
"... | class class_name[name] begin[{]
method[writeInterface, return_type[void], modifier[private], parameter[context, logger, bean]] begin[{]
local_variable[type[PrintWriter], pw]
if[binary_operation[member[.pw], !=, literal[null]]] begin[{]
local_variable[type[TreeLogger], interf... | Keyword[private] Keyword[void] identifier[writeInterface] operator[SEP] Keyword[final] identifier[GeneratorContext] identifier[context] , Keyword[final] identifier[TreeLogger] identifier[logger] , Keyword[final] identifier[BeanHelper] identifier[bean] operator[SEP] {
Keyword[final] identifier[PrintWriter] iden... |
private void grow() {
final Activation[] elements = new Activation[this.elements.length * 2];
System.arraycopy( this.elements,
0,
elements,
0,
this.elements.length );
this.elements = elements;... | class class_name[name] begin[{]
method[grow, return_type[void], modifier[private], parameter[]] begin[{]
local_variable[type[Activation], elements]
call[System.arraycopy, parameter[THIS[member[None.elements]], literal[0], member[.elements], literal[0], THIS[member[None.elements]member[N... | Keyword[private] Keyword[void] identifier[grow] operator[SEP] operator[SEP] {
Keyword[final] identifier[Activation] operator[SEP] operator[SEP] identifier[elements] operator[=] Keyword[new] identifier[Activation] operator[SEP] Keyword[this] operator[SEP] identifier[elements] operator[SEP] identifier[length] oper... |
public Task<Void> confirmUser(@NonNull final String token, @NonNull final String tokenId) {
return dispatcher.dispatchTask(
new Callable<Void>() {
@Override
public Void call() {
confirmUserInternal(token, tokenId);
return null;
}
});
} | class class_name[name] begin[{]
method[confirmUser, return_type[type[Task]], modifier[public], parameter[token, tokenId]] begin[{]
return[call[dispatcher.dispatchTask, parameter[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[StatementExpr... | Keyword[public] identifier[Task] operator[<] identifier[Void] operator[>] identifier[confirmUser] operator[SEP] annotation[@] identifier[NonNull] Keyword[final] identifier[String] identifier[token] , annotation[@] identifier[NonNull] Keyword[final] identifier[String] identifier[tokenId] operator[SEP] {
Keyword[... |
@SuppressWarnings("unchecked")
protected String addPostRunDependent(Creatable<? extends Indexable> creatable) {
TaskGroup.HasTaskGroup dependency = (TaskGroup.HasTaskGroup) creatable;
return this.addPostRunDependent(dependency);
} | class class_name[name] begin[{]
method[addPostRunDependent, return_type[type[String]], modifier[protected], parameter[creatable]] begin[{]
local_variable[type[TaskGroup], dependency]
return[THIS[call[None.addPostRunDependent, parameter[member[.dependency]]]]]
end[}]
END[}] | annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[protected] identifier[String] identifier[addPostRunDependent] operator[SEP] identifier[Creatable] operator[<] operator[?] Keyword[extends] identifier[Indexable] operator[>] identifier[creatable] operator[SEP] {
identif... |
private QueryParameters.Direction convertToDirection(int columnType) {
QueryParameters.Direction result = null;
if (columnType == DatabaseMetaData.procedureColumnIn) {
result = QueryParameters.Direction.IN;
} else if (columnType == DatabaseMetaData.procedureColumnInOut) {
... | class class_name[name] begin[{]
method[convertToDirection, return_type[type[QueryParameters]], modifier[private], parameter[columnType]] begin[{]
local_variable[type[QueryParameters], result]
if[binary_operation[member[.columnType], ==, member[DatabaseMetaData.procedureColumnIn]]] begin... | Keyword[private] identifier[QueryParameters] operator[SEP] identifier[Direction] identifier[convertToDirection] operator[SEP] Keyword[int] identifier[columnType] operator[SEP] {
identifier[QueryParameters] operator[SEP] identifier[Direction] identifier[result] operator[=] Other[null] operator[SEP] Keyword[if] op... |
public void marshall(StartAutomationExecutionRequest startAutomationExecutionRequest, ProtocolMarshaller protocolMarshaller) {
if (startAutomationExecutionRequest == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarsha... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[startAutomationExecutionRequest, protocolMarshaller]] begin[{]
if[binary_operation[member[.startAutomationExecutionRequest], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCr... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[StartAutomationExecutionRequest] identifier[startAutomationExecutionRequest] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[startAutomationExecutionRequest] operator[... |
private void handleMasterNodeChange() {
try {
synchronized (hasActiveServer) {
if (ZooKeeperUtil.watchAndCheckExists(this, masterZnode)) {
// A master node exists, there is an active master
if (LOG.isDebugEnabled()) {
LOG.debug("A master is now available");
}
... | class class_name[name] begin[{]
method[handleMasterNodeChange, return_type[void], modifier[private], parameter[]] begin[{]
TryStatement(block=[SynchronizedStatement(block=[IfStatement(condition=MethodInvocation(arguments=[This(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[]), Me... | Keyword[private] Keyword[void] identifier[handleMasterNodeChange] operator[SEP] operator[SEP] {
Keyword[try] {
Keyword[synchronized] operator[SEP] identifier[hasActiveServer] operator[SEP] {
Keyword[if] operator[SEP] identifier[ZooKeeperUtil] operator[SEP] identifier[watchAndCheckExists... |
public final <V, C extends Collection<? super V>> Flux<T> distinct(
Function<? super T, ? extends V> keySelector,
Supplier<C> distinctCollectionSupplier) {
return this.distinct(keySelector, distinctCollectionSupplier, Collection::add, Collection::clear);
} | class class_name[name] begin[{]
method[distinct, return_type[type[Flux]], modifier[final public], parameter[keySelector, distinctCollectionSupplier]] begin[{]
return[THIS[call[None.distinct, parameter[member[.keySelector], member[.distinctCollectionSupplier], MethodReference(expression=MemberReference(... | Keyword[public] Keyword[final] operator[<] identifier[V] , identifier[C] Keyword[extends] identifier[Collection] operator[<] operator[?] Keyword[super] identifier[V] operator[>] operator[>] identifier[Flux] operator[<] identifier[T] operator[>] identifier[distinct] operator[SEP] identifier[Function] operator[<] operat... |
public void println() throws IOException
{
if(this._listener!= null && !checkIfCalledFromWLonError()){
_outHelper.write_NonBlocking(CRLF, 0, 2);
}
else {
this.write(CRLF, 0, 2);
}
} | class class_name[name] begin[{]
method[println, return_type[void], modifier[public], parameter[]] begin[{]
if[binary_operation[binary_operation[THIS[member[None._listener]], !=, literal[null]], &&, call[.checkIfCalledFromWLonError, parameter[]]]] begin[{]
call[_outHelper... | Keyword[public] Keyword[void] identifier[println] operator[SEP] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[_listener] operator[!=] Other[null] operator[&&] operator[!] identifier[checkIfCalledFromWLonError] operator[SEP] operator[SEP] ... |
@Override
public void dropRetentionPolicy(final String rpName, final String database) {
Preconditions.checkNonEmptyString(rpName, "retentionPolicyName");
Preconditions.checkNonEmptyString(database, "database");
StringBuilder queryBuilder = new StringBuilder("DROP RETENTION POLICY \"");
queryBuilder.ap... | class class_name[name] begin[{]
method[dropRetentionPolicy, return_type[void], modifier[public], parameter[rpName, database]] begin[{]
call[Preconditions.checkNonEmptyString, parameter[member[.rpName], literal["retentionPolicyName"]]]
call[Preconditions.checkNonEmptyString, para... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[dropRetentionPolicy] operator[SEP] Keyword[final] identifier[String] identifier[rpName] , Keyword[final] identifier[String] identifier[database] operator[SEP] {
identifier[Preconditions] operator[SEP] identifier[checkNonEmptyString] ope... |
@OnMessage
public void onMessage(Dto msg, Session session) {
try {
messageBus.fire(session);
messagePayloadBus.fire(msg);
} catch (Exception e) {
log.log(Level.SEVERE, e.getMessage(), e);
}
} | class class_name[name] begin[{]
method[onMessage, return_type[void], modifier[public], parameter[msg, session]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference(member=session, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], ... | annotation[@] identifier[OnMessage] Keyword[public] Keyword[void] identifier[onMessage] operator[SEP] identifier[Dto] identifier[msg] , identifier[Session] identifier[session] operator[SEP] {
Keyword[try] {
identifier[messageBus] operator[SEP] identifier[fire] operator[SEP] identifier[session] operat... |
public void seqAssign(int idx, Object id) {
((Data.Seq)data).items[idx] = id;
} | class class_name[name] begin[{]
method[seqAssign, return_type[void], modifier[public], parameter[idx, id]] begin[{]
assign[Cast(expression=MemberReference(member=data, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), type=ReferenceType(arguments=None, dimensions=[], name=Da... | Keyword[public] Keyword[void] identifier[seqAssign] operator[SEP] Keyword[int] identifier[idx] , identifier[Object] identifier[id] operator[SEP] {
operator[SEP] operator[SEP] identifier[Data] operator[SEP] identifier[Seq] operator[SEP] identifier[data] operator[SEP] operator[SEP] identifier[items] operator[SEP]... |
@Override
public void requestRide(@NonNull Context context, @NonNull RideParameters params) {
RideRequestDeeplink deeplink = new RideRequestDeeplink.Builder(context)
.setSessionConfiguration(sessionConfiguration)
.setRideParameters(params).build();
deeplink.execute();... | class class_name[name] begin[{]
method[requestRide, return_type[void], modifier[public], parameter[context, params]] begin[{]
local_variable[type[RideRequestDeeplink], deeplink]
call[deeplink.execute, parameter[]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[requestRide] operator[SEP] annotation[@] identifier[NonNull] identifier[Context] identifier[context] , annotation[@] identifier[NonNull] identifier[RideParameters] identifier[params] operator[SEP] {
identifier[RideRequestDeeplink] ident... |
@Help(help = "create VNFCInstance. Aka SCALE OUT")
public void createVNFCInstance(
final String idNsr,
final String idVnfr,
final VNFComponent vnfComponent,
ArrayList<String> vimInstanceNames)
throws SDKException {
String url = idNsr + "/vnfrecords/" + idVnfr + "/vdunits/vnfcinstance... | class class_name[name] begin[{]
method[createVNFCInstance, return_type[void], modifier[public], parameter[idNsr, idVnfr, vnfComponent, vimInstanceNames]] begin[{]
local_variable[type[String], url]
local_variable[type[HashMap], body]
call[body.put, parameter[literal["vnfComponent... | annotation[@] identifier[Help] operator[SEP] identifier[help] operator[=] literal[String] operator[SEP] Keyword[public] Keyword[void] identifier[createVNFCInstance] operator[SEP] Keyword[final] identifier[String] identifier[idNsr] , Keyword[final] identifier[String] identifier[idVnfr] , Keyword[final] identifier[VNFC... |
MonocleWindow getWindow(boolean recalculateCache) {
if (window == null || recalculateCache) {
window = (MonocleWindow)
MonocleWindowManager.getInstance().getFocusedWindow();
}
return window;
} | class class_name[name] begin[{]
method[getWindow, return_type[type[MonocleWindow]], modifier[default], parameter[recalculateCache]] begin[{]
if[binary_operation[binary_operation[member[.window], ==, literal[null]], ||, member[.recalculateCache]]] begin[{]
assign[member[.... | identifier[MonocleWindow] identifier[getWindow] operator[SEP] Keyword[boolean] identifier[recalculateCache] operator[SEP] {
Keyword[if] operator[SEP] identifier[window] operator[==] Other[null] operator[||] identifier[recalculateCache] operator[SEP] {
identifier[window] operator[=] operator[SEP] ident... |
public static MongoClient create(final PippoSettings settings) {
String host = settings.getString(HOST, "mongodb://localhost:27017");
return create(host);
} | class class_name[name] begin[{]
method[create, return_type[type[MongoClient]], modifier[public static], parameter[settings]] begin[{]
local_variable[type[String], host]
return[call[.create, parameter[member[.host]]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[MongoClient] identifier[create] operator[SEP] Keyword[final] identifier[PippoSettings] identifier[settings] operator[SEP] {
identifier[String] identifier[host] operator[=] identifier[settings] operator[SEP] identifier[getString] operator[SEP] identifier[HOST] , literal... |
private static @NotNull Optional<List<Type>> findTargetTypes(@NotNull Constructor<?> ctor, @NotNull List<String> resultSetColumns) {
List<Type> constructorParameterTypes = asList(ctor.getGenericParameterTypes());
int constructorParameterCount = constructorParameterTypes.size();
if (constructor... | class class_name[name] begin[{]
method[findTargetTypes, return_type[type[Optional]], modifier[private static], parameter[ctor, resultSetColumns]] begin[{]
local_variable[type[List], constructorParameterTypes]
local_variable[type[int], constructorParameterCount]
if[binary_operati... | Keyword[private] Keyword[static] annotation[@] identifier[NotNull] identifier[Optional] operator[<] identifier[List] operator[<] identifier[Type] operator[>] operator[>] identifier[findTargetTypes] operator[SEP] annotation[@] identifier[NotNull] identifier[Constructor] operator[<] operator[?] operator[>] identifier[cto... |
public static FractionDescriptor fromGav(final FractionList fractionList, final String gav) {
final String[] parts = gav.split(":");
FractionDescriptor desc = null;
switch (parts.length) {
case 1:
desc = fractionList.getFractionDescriptor(THORNTAIL_GROUP_ID, parts[0]... | class class_name[name] begin[{]
method[fromGav, return_type[type[FractionDescriptor]], modifier[public static], parameter[fractionList, gav]] begin[{]
local_variable[type[String], parts]
local_variable[type[FractionDescriptor], desc]
SwitchStatement(cases=[SwitchStatementCase(case=[Lite... | Keyword[public] Keyword[static] identifier[FractionDescriptor] identifier[fromGav] operator[SEP] Keyword[final] identifier[FractionList] identifier[fractionList] , Keyword[final] identifier[String] identifier[gav] operator[SEP] {
Keyword[final] identifier[String] operator[SEP] operator[SEP] identifier[parts] op... |
protected String generateHashcode(Object id) {
return Hashing.crc32().hashString(id.toString(), UTF_8).toString();
} | class class_name[name] begin[{]
method[generateHashcode, return_type[type[String]], modifier[protected], parameter[id]] begin[{]
return[call[Hashing.crc32, parameter[]]]
end[}]
END[}] | Keyword[protected] identifier[String] identifier[generateHashcode] operator[SEP] identifier[Object] identifier[id] operator[SEP] {
Keyword[return] identifier[Hashing] operator[SEP] identifier[crc32] operator[SEP] operator[SEP] operator[SEP] identifier[hashString] operator[SEP] identifier[id] operator[SEP] identi... |
public WebhookCluster removeWebhooks(WebhookClient... clients)
{
Checks.notNull(clients, "Clients");
webhooks.removeAll(Arrays.asList(clients));
return this;
} | class class_name[name] begin[{]
method[removeWebhooks, return_type[type[WebhookCluster]], modifier[public], parameter[clients]] begin[{]
call[Checks.notNull, parameter[member[.clients], literal["Clients"]]]
call[webhooks.removeAll, parameter[call[Arrays.asList, parameter[member[... | Keyword[public] identifier[WebhookCluster] identifier[removeWebhooks] operator[SEP] identifier[WebhookClient] operator[...] identifier[clients] operator[SEP] {
identifier[Checks] operator[SEP] identifier[notNull] operator[SEP] identifier[clients] , literal[String] operator[SEP] operator[SEP] identifier[webhooks... |
@Override
@SuppressWarnings("checkstyle:magicnumber")
public void clear() {
if (this.child1 != null) {
final N child = this.child1;
setChildAt(0, null);
child.clear();
}
if (this.child2 != null) {
final N child = this.child2;
setChildAt(1, null);
child.clear();
}
if (this.child3 != null) {... | class class_name[name] begin[{]
method[clear, return_type[void], modifier[public], parameter[]] begin[{]
if[binary_operation[THIS[member[None.child1]], !=, literal[null]]] begin[{]
local_variable[type[N], child]
call[.setChildAt, parameter[literal[0], literal... | annotation[@] identifier[Override] annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] Keyword[public] Keyword[void] identifier[clear] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[child1] operator[!=] Other[null] operator[SEP] ... |
private MBeanInfo getMBeanInfo(MBeanServerExecutor pServerManager, ObjectName pObjectName)
throws IOException, ReflectionException, MBeanException, AttributeNotFoundException, InstanceNotFoundException {
return pServerManager.call(pObjectName, MBEAN_INFO_HANDLER);
} | class class_name[name] begin[{]
method[getMBeanInfo, return_type[type[MBeanInfo]], modifier[private], parameter[pServerManager, pObjectName]] begin[{]
return[call[pServerManager.call, parameter[member[.pObjectName], member[.MBEAN_INFO_HANDLER]]]]
end[}]
END[}] | Keyword[private] identifier[MBeanInfo] identifier[getMBeanInfo] operator[SEP] identifier[MBeanServerExecutor] identifier[pServerManager] , identifier[ObjectName] identifier[pObjectName] operator[SEP] Keyword[throws] identifier[IOException] , identifier[ReflectionException] , identifier[MBeanException] , identifier[... |
public CMSEnvelopedData encode(final byte[] messageData)
throws MessageEncodingException {
LOGGER.debug("Encoding pkcsPkiEnvelope");
CMSEnvelopedDataGenerator edGenerator = new CMSEnvelopedDataGenerator();
CMSTypedData envelopable = new CMSProcessableByteArray(messageData);
R... | class class_name[name] begin[{]
method[encode, return_type[type[CMSEnvelopedData]], modifier[public], parameter[messageData]] begin[{]
call[LOGGER.debug, parameter[literal["Encoding pkcsPkiEnvelope"]]]
local_variable[type[CMSEnvelopedDataGenerator], edGenerator]
local_variable[t... | Keyword[public] identifier[CMSEnvelopedData] identifier[encode] operator[SEP] Keyword[final] Keyword[byte] operator[SEP] operator[SEP] identifier[messageData] operator[SEP] Keyword[throws] identifier[MessageEncodingException] {
identifier[LOGGER] operator[SEP] identifier[debug] operator[SEP] literal[String] oper... |
public Dictionary getDictionary(String baseFileName)
throws IOException {
if (map.containsKey(baseFileName)) {
return map.get(baseFileName);
} else {
Dictionary d = new Dictionary(baseFileName);
map.put(baseFileName, d);
return d;
}
... | class class_name[name] begin[{]
method[getDictionary, return_type[type[Dictionary]], modifier[public], parameter[baseFileName]] begin[{]
if[call[map.containsKey, parameter[member[.baseFileName]]]] begin[{]
return[call[map.get, parameter[member[.baseFileName]]]]
else begin[{]... | Keyword[public] identifier[Dictionary] identifier[getDictionary] operator[SEP] identifier[String] identifier[baseFileName] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[if] operator[SEP] identifier[map] operator[SEP] identifier[containsKey] operator[SEP] identifier[baseFileName] operator[SEP] o... |
private void buildData(String path, WebPage page, List<TreePageData> data, WebSiteRequest req) throws IOException, SQLException {
if(isVisible(page)) {
if(path.length()>0) path=path+'/'+page.getShortTitle();
else path=page.getShortTitle();
WebPage[] pages=page.getCachedPages(req);
int len=pages.length;
... | class class_name[name] begin[{]
method[buildData, return_type[void], modifier[private], parameter[path, page, data, req]] begin[{]
if[call[.isVisible, parameter[member[.page]]]] begin[{]
if[binary_operation[call[path.length, parameter[]], >, literal[0]]] begin[{]
... | Keyword[private] Keyword[void] identifier[buildData] operator[SEP] identifier[String] identifier[path] , identifier[WebPage] identifier[page] , identifier[List] operator[<] identifier[TreePageData] operator[>] identifier[data] , identifier[WebSiteRequest] identifier[req] operator[SEP] Keyword[throws] identifier[IOEx... |
public static void swap(int[] intArray, int index1, int index2) {
XORSwap.swap(intArray, index1, intArray, index2);
} | class class_name[name] begin[{]
method[swap, return_type[void], modifier[public static], parameter[intArray, index1, index2]] begin[{]
call[XORSwap.swap, parameter[member[.intArray], member[.index1], member[.intArray], member[.index2]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[void] identifier[swap] operator[SEP] Keyword[int] operator[SEP] operator[SEP] identifier[intArray] , Keyword[int] identifier[index1] , Keyword[int] identifier[index2] operator[SEP] {
identifier[XORSwap] operator[SEP] identifier[swap] operator[SEP] identifier[intArray] , ... |
@Override
public EEnum getIfcAnalysisModelTypeEnum() {
if (ifcAnalysisModelTypeEnumEEnum == null) {
ifcAnalysisModelTypeEnumEEnum = (EEnum) EPackage.Registry.INSTANCE.getEPackage(Ifc4Package.eNS_URI)
.getEClassifiers().get(913);
}
return ifcAnalysisModelTypeEnumEEnum;
} | class class_name[name] begin[{]
method[getIfcAnalysisModelTypeEnum, return_type[type[EEnum]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.ifcAnalysisModelTypeEnumEEnum], ==, literal[null]]] begin[{]
assign[member[.ifcAnalysisModelTypeEnumEEnum], C... | annotation[@] identifier[Override] Keyword[public] identifier[EEnum] identifier[getIfcAnalysisModelTypeEnum] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[ifcAnalysisModelTypeEnumEEnum] operator[==] Other[null] operator[SEP] {
identifier[ifcAnalysisModelTypeEnumEEnum] operator[=] ... |
public Observable<ServiceResponse<HybridConnectionKeyInner>> listHybridConnectionKeysWithServiceResponseAsync(String resourceGroupName, String name, String namespaceName, String relayName) {
if (resourceGroupName == null) {
throw new IllegalArgumentException("Parameter resourceGroupName is required ... | class class_name[name] begin[{]
method[listHybridConnectionKeysWithServiceResponseAsync, return_type[type[Observable]], modifier[public], parameter[resourceGroupName, name, namespaceName, relayName]] begin[{]
if[binary_operation[member[.resourceGroupName], ==, literal[null]]] begin[{]
... | Keyword[public] identifier[Observable] operator[<] identifier[ServiceResponse] operator[<] identifier[HybridConnectionKeyInner] operator[>] operator[>] identifier[listHybridConnectionKeysWithServiceResponseAsync] operator[SEP] identifier[String] identifier[resourceGroupName] , identifier[String] identifier[name] , id... |
public StringBuffer markdown(Schema sinput, Schema soutput) {
MarkdownBuilder builder = new MarkdownBuilder();
builder.comment("Preview with http://jbt.github.io/markdown-editor");
builder.heading1(_http_method, _url);
builder.hline();
builder.paragraph(_summary);
// parameters and output tables... | class class_name[name] begin[{]
method[markdown, return_type[type[StringBuffer]], modifier[public], parameter[sinput, soutput]] begin[{]
local_variable[type[MarkdownBuilder], builder]
call[builder.comment, parameter[literal["Preview with http://jbt.github.io/markdown-editor"]]]
... | Keyword[public] identifier[StringBuffer] identifier[markdown] operator[SEP] identifier[Schema] identifier[sinput] , identifier[Schema] identifier[soutput] operator[SEP] {
identifier[MarkdownBuilder] identifier[builder] operator[=] Keyword[new] identifier[MarkdownBuilder] operator[SEP] operator[SEP] operator[SEP... |
static @Nullable <V> V getWhenSuccessful(@Nullable CompletableFuture<V> future) {
try {
return (future == null) ? null : future.get();
} catch (InterruptedException e) {
Thread.currentThread().interrupt();
return null;
} catch (ExecutionException e) {
return null;
}
} | class class_name[name] begin[{]
method[getWhenSuccessful, return_type[type[V]], modifier[static], parameter[future]] begin[{]
TryStatement(block=[ReturnStatement(expression=TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=future, postfix_operators=[], prefix_operators=[], qua... | Keyword[static] annotation[@] identifier[Nullable] operator[<] identifier[V] operator[>] identifier[V] identifier[getWhenSuccessful] operator[SEP] annotation[@] identifier[Nullable] identifier[CompletableFuture] operator[<] identifier[V] operator[>] identifier[future] operator[SEP] {
Keyword[try] {
Ke... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.