code stringlengths 63 466k | code_sememe stringlengths 141 3.79M | token_type stringlengths 274 1.23M |
|---|---|---|
private boolean shouldUseTempFolderForDestination(String destination) {
destination = removeLeadingSlash(destination);
for (String tempFolderDestination : m_tempFolderDestinations) {
tempFolderDestination = removeLeadingSlash(tempFolderDestination);
if (CmsStringUtil.isPrefixPat... | class class_name[name] begin[{]
method[shouldUseTempFolderForDestination, return_type[type[boolean]], modifier[private], parameter[destination]] begin[{]
assign[member[.destination], call[.removeLeadingSlash, parameter[member[.destination]]]]
ForStatement(body=BlockStatement(label=None,... | Keyword[private] Keyword[boolean] identifier[shouldUseTempFolderForDestination] operator[SEP] identifier[String] identifier[destination] operator[SEP] {
identifier[destination] operator[=] identifier[removeLeadingSlash] operator[SEP] identifier[destination] operator[SEP] operator[SEP] Keyword[for] operator[SEP] ... |
protected final boolean reindex( String workspaceName,
NodeKey key,
Path path,
Name primaryType,
Set<Name> mixinTypes,
Properties prope... | class class_name[name] begin[{]
method[reindex, return_type[type[boolean]], modifier[final protected], parameter[workspaceName, key, path, primaryType, mixinTypes, properties, queryable]] begin[{]
if[call[predicate.matchesType, parameter[member[.primaryType], member[.mixinTypes]]]] begin[{]
... | Keyword[protected] Keyword[final] Keyword[boolean] identifier[reindex] operator[SEP] identifier[String] identifier[workspaceName] , identifier[NodeKey] identifier[key] , identifier[Path] identifier[path] , identifier[Name] identifier[primaryType] , identifier[Set] operator[<] identifier[Name] operator[>] identifier... |
public void setAll(int[] samples, int count, int start, int skip,
long frameNumber, EncodedElement result) {
// assert(start == 0);
this.samples = samples;
this.count = count;
this.start = start;
this.skip = skip;
this.frameNumber = frameNumber;
this.result = result;
valid = false;
... | class class_name[name] begin[{]
method[setAll, return_type[void], modifier[public], parameter[samples, count, start, skip, frameNumber, result]] begin[{]
assign[THIS[member[None.samples]], member[.samples]]
assign[THIS[member[None.count]], member[.count]]
assign[... | Keyword[public] Keyword[void] identifier[setAll] operator[SEP] Keyword[int] operator[SEP] operator[SEP] identifier[samples] , Keyword[int] identifier[count] , Keyword[int] identifier[start] , Keyword[int] identifier[skip] , Keyword[long] identifier[frameNumber] , identifier[EncodedElement] identifier[result] opera... |
private static void validate(String name, Collection<Geometry> geometries, int extent) {
if (name == null) {
throw new IllegalArgumentException("layer name is null");
}
if (geometries == null) {
throw new IllegalArgumentException("geometry collection is null");
}
... | class class_name[name] begin[{]
method[validate, return_type[void], modifier[private static], parameter[name, geometries, extent]] begin[{]
if[binary_operation[member[.name], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[],... | Keyword[private] Keyword[static] Keyword[void] identifier[validate] operator[SEP] identifier[String] identifier[name] , identifier[Collection] operator[<] identifier[Geometry] operator[>] identifier[geometries] , Keyword[int] identifier[extent] operator[SEP] {
Keyword[if] operator[SEP] identifier[name] operato... |
private static <E, F extends E, C extends Collection<F>> C collectionFilter(C collection, Iterable<? extends E> elements, Class<F> clazz) {
for (E e : elements) {
//if (clazz.isAssignableFrom(e.getClass()))
if (clazz.isInstance(e))
collection.add(clazz.cast(e));
}
return collection;
} | class class_name[name] begin[{]
method[collectionFilter, return_type[type[C]], modifier[private static], parameter[collection, elements, clazz]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=e, postfix_operator... | Keyword[private] Keyword[static] operator[<] identifier[E] , identifier[F] Keyword[extends] identifier[E] , identifier[C] Keyword[extends] identifier[Collection] operator[<] identifier[F] operator[>] operator[>] identifier[C] identifier[collectionFilter] operator[SEP] identifier[C] identifier[collection] , identifie... |
@Nonnull
public FineUploader5Form setElementID (@Nonnull @Nonempty final String sElementID)
{
ValueEnforcer.notEmpty (sElementID, "ElementID");
m_sFormElementID = sElementID;
return this;
} | class class_name[name] begin[{]
method[setElementID, return_type[type[FineUploader5Form]], modifier[public], parameter[sElementID]] begin[{]
call[ValueEnforcer.notEmpty, parameter[member[.sElementID], literal["ElementID"]]]
assign[member[.m_sFormElementID], member[.sElementID]]
... | annotation[@] identifier[Nonnull] Keyword[public] identifier[FineUploader5Form] identifier[setElementID] operator[SEP] annotation[@] identifier[Nonnull] annotation[@] identifier[Nonempty] Keyword[final] identifier[String] identifier[sElementID] operator[SEP] {
identifier[ValueEnforcer] operator[SEP] identifier[n... |
public Long getLongProperty(String pstrSection, String pstrProp)
{
Long lngRet = null;
String strVal = null;
INIProperty objProp = null;
INISection objSec = null;
objSec = (INISection) this.mhmapSections.get(pstrSection);
if (objSec != null)
... | class class_name[name] begin[{]
method[getLongProperty, return_type[type[Long]], modifier[public], parameter[pstrSection, pstrProp]] begin[{]
local_variable[type[Long], lngRet]
local_variable[type[String], strVal]
local_variable[type[INIProperty], objProp]
local_variable[type[IN... | Keyword[public] identifier[Long] identifier[getLongProperty] operator[SEP] identifier[String] identifier[pstrSection] , identifier[String] identifier[pstrProp] operator[SEP] {
identifier[Long] identifier[lngRet] operator[=] Other[null] operator[SEP] identifier[String] identifier[strVal] operator[=] Other[null] ... |
public static Iterator<ImageWriter> getImageWriters(ImageTypeSpecifier type, String formatName) {
if (type == null) {
throw new IllegalArgumentException("type == null!");
}
if (formatName == null) {
throw new IllegalArgumentException("formatName == null!");
}
Iterator iter;
// Ensure categor... | class class_name[name] begin[{]
method[getImageWriters, return_type[type[Iterator]], modifier[public static], parameter[type, formatName]] begin[{]
if[binary_operation[member[.type], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_opera... | Keyword[public] Keyword[static] identifier[Iterator] operator[<] identifier[ImageWriter] operator[>] identifier[getImageWriters] operator[SEP] identifier[ImageTypeSpecifier] identifier[type] , identifier[String] identifier[formatName] operator[SEP] {
Keyword[if] operator[SEP] identifier[type] operator[==] Other... |
public static org.postgis.Geometry convert(Geometry geometry) {
if (geometry instanceof Point) {
return convert((Point) geometry);
} else if (geometry instanceof LinearRing) {
return convert((LinearRing) geometry);
} else if (geometry instanceof LineString) {
... | class class_name[name] begin[{]
method[convert, return_type[type[org]], modifier[public static], parameter[geometry]] begin[{]
if[binary_operation[member[.geometry], instanceof, type[Point]]] begin[{]
return[call[.convert, parameter[Cast(expression=MemberReference(member=geometry, p... | Keyword[public] Keyword[static] identifier[org] operator[SEP] identifier[postgis] operator[SEP] identifier[Geometry] identifier[convert] operator[SEP] identifier[Geometry] identifier[geometry] operator[SEP] {
Keyword[if] operator[SEP] identifier[geometry] Keyword[instanceof] identifier[Point] operator[SEP] {
... |
@Override
public long getLastModified() {
return AccessController.doPrivileged(new PrivilegedAction<Long>() {
@Override
public Long run() {
return file.lastModified();
}
});
} | class class_name[name] begin[{]
method[getLastModified, return_type[type[long]], modifier[public], parameter[]] begin[{]
return[call[AccessController.doPrivileged, parameter[ClassCreator(arguments=[], body=[MethodDeclaration(annotations=[Annotation(element=None, name=Override)], body=[ReturnStatement(e... | annotation[@] identifier[Override] Keyword[public] Keyword[long] identifier[getLastModified] operator[SEP] operator[SEP] {
Keyword[return] identifier[AccessController] operator[SEP] identifier[doPrivileged] operator[SEP] Keyword[new] identifier[PrivilegedAction] operator[<] identifier[Long] operator[>] operator[... |
public final Mono<Boolean> hasElement(T value) {
Objects.requireNonNull(value, "value");
return any(t -> Objects.equals(value, t));
} | class class_name[name] begin[{]
method[hasElement, return_type[type[Mono]], modifier[final public], parameter[value]] begin[{]
call[Objects.requireNonNull, parameter[member[.value], literal["value"]]]
return[call[.any, parameter[LambdaExpression(body=MethodInvocation(arguments=[MemberRe... | Keyword[public] Keyword[final] identifier[Mono] operator[<] identifier[Boolean] operator[>] identifier[hasElement] operator[SEP] identifier[T] identifier[value] operator[SEP] {
identifier[Objects] operator[SEP] identifier[requireNonNull] operator[SEP] identifier[value] , literal[String] operator[SEP] operator[S... |
public void
writeU16(int val) {
check(val, 16);
need(2);
array[pos++] = (byte)((val >>> 8) & 0xFF);
array[pos++] = (byte)(val & 0xFF);
} | class class_name[name] begin[{]
method[writeU16, return_type[void], modifier[public], parameter[val]] begin[{]
call[.check, parameter[member[.val], literal[16]]]
call[.need, parameter[literal[2]]]
assign[member[.array], Cast(expression=BinaryOperation(operandl=Bi... | Keyword[public] Keyword[void] identifier[writeU16] operator[SEP] Keyword[int] identifier[val] operator[SEP] {
identifier[check] operator[SEP] identifier[val] , Other[16] operator[SEP] operator[SEP] identifier[need] operator[SEP] Other[2] operator[SEP] operator[SEP] identifier[array] operator[SEP] identifier[pos... |
protected UIOutput createVerbatimComponent() {
assert(null != getFacesContext());
UIOutput verbatim;
Application application = getFacesContext().getApplication();
verbatim = (UIOutput)
application.createComponent("javax.faces.HtmlOutputText");
verbatim.setTransien... | class class_name[name] begin[{]
method[createVerbatimComponent, return_type[type[UIOutput]], modifier[protected], parameter[]] begin[{]
AssertStatement(condition=BinaryOperation(operandl=Literal(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[], value=null), operandr=MethodInvocat... | Keyword[protected] identifier[UIOutput] identifier[createVerbatimComponent] operator[SEP] operator[SEP] {
Keyword[assert] operator[SEP] Other[null] operator[!=] identifier[getFacesContext] operator[SEP] operator[SEP] operator[SEP] operator[SEP] identifier[UIOutput] identifier[verbatim] operator[SEP] identifier[A... |
synchronized void offer(TransactionTask task)
{
Iv2Trace.logTransactionTaskQueueOffer(task);
TransactionState txnState = task.getTransactionState();
if (!m_backlog.isEmpty()) {
/*
* This branch happens during regular execution when a multi-part is in progress.
... | class class_name[name] begin[{]
method[offer, return_type[void], modifier[synchronized], parameter[task]] begin[{]
call[Iv2Trace.logTransactionTaskQueueOffer, parameter[member[.task]]]
local_variable[type[TransactionState], txnState]
if[call[m_backlog.isEmpty, parameter[... | Keyword[synchronized] Keyword[void] identifier[offer] operator[SEP] identifier[TransactionTask] identifier[task] operator[SEP] {
identifier[Iv2Trace] operator[SEP] identifier[logTransactionTaskQueueOffer] operator[SEP] identifier[task] operator[SEP] operator[SEP] identifier[TransactionState] identifier[txnState]... |
@Override
public void keep(String key)
{
_checkFlashScopeDisabled();
FacesContext facesContext = FacesContext.getCurrentInstance();
Map<String, Object> requestMap = facesContext.getExternalContext().getRequestMap();
Object value = requestMap.get(key);
// if the k... | class class_name[name] begin[{]
method[keep, return_type[void], modifier[public], parameter[key]] begin[{]
call[._checkFlashScopeDisabled, parameter[]]
local_variable[type[FacesContext], facesContext]
local_variable[type[Map], requestMap]
local_variable[type[Object], val... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[keep] operator[SEP] identifier[String] identifier[key] operator[SEP] {
identifier[_checkFlashScopeDisabled] operator[SEP] operator[SEP] operator[SEP] identifier[FacesContext] identifier[facesContext] operator[=] identifier[FacesContext] ... |
public static boolean needsHeatmapJs(final Options options) {
return
options.getChart() != null &&
(options.getChart().getType() == SeriesType.HEATMAP);
} | class class_name[name] begin[{]
method[needsHeatmapJs, return_type[type[boolean]], modifier[public static], parameter[options]] begin[{]
return[binary_operation[binary_operation[call[options.getChart, parameter[]], !=, literal[null]], &&, binary_operation[call[options.getChart, parameter[]], ==, member... | Keyword[public] Keyword[static] Keyword[boolean] identifier[needsHeatmapJs] operator[SEP] Keyword[final] identifier[Options] identifier[options] operator[SEP] {
Keyword[return] identifier[options] operator[SEP] identifier[getChart] operator[SEP] operator[SEP] operator[!=] Other[null] operator[&&] operator[SEP] i... |
public CompactionParserResult parse (FileSystemDataset dataset) {
CompactionParserResult result = new CompactionParserResult();
result.srcBaseDir = getSrcBaseDir (state);
result.srcSubDir = getSrcSubDir (state);
result.dstBaseDir = getDstBaseDir (state);
result.dstSubDir = getDstSubDir (state);... | class class_name[name] begin[{]
method[parse, return_type[type[CompactionParserResult]], modifier[public], parameter[dataset]] begin[{]
local_variable[type[CompactionParserResult], result]
assign[member[result.srcBaseDir], call[.getSrcBaseDir, parameter[member[.state]]]]
... | Keyword[public] identifier[CompactionParserResult] identifier[parse] operator[SEP] identifier[FileSystemDataset] identifier[dataset] operator[SEP] {
identifier[CompactionParserResult] identifier[result] operator[=] Keyword[new] identifier[CompactionParserResult] operator[SEP] operator[SEP] operator[SEP] identifi... |
public String convertIfcConstructionProductResourceTypeEnumToString(EDataType eDataType, Object instanceValue) {
return instanceValue == null ? null : instanceValue.toString();
} | class class_name[name] begin[{]
method[convertIfcConstructionProductResourceTypeEnumToString, return_type[type[String]], modifier[public], parameter[eDataType, instanceValue]] begin[{]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=instanceValue, postfix_operators=[]... | Keyword[public] identifier[String] identifier[convertIfcConstructionProductResourceTypeEnumToString] operator[SEP] identifier[EDataType] identifier[eDataType] , identifier[Object] identifier[instanceValue] operator[SEP] {
Keyword[return] identifier[instanceValue] operator[==] Other[null] operator[?] Other[null]... |
public void value(AjaxRequestTarget ajaxRequestTarget, int value)
{
ajaxRequestTarget.appendJavaScript(this.value(value).render().toString());
} | class class_name[name] begin[{]
method[value, return_type[void], modifier[public], parameter[ajaxRequestTarget, value]] begin[{]
call[ajaxRequestTarget.appendJavaScript, parameter[THIS[call[None.value, parameter[member[.value]]]call[None.render, parameter[]]call[None.toString, parameter[]]]]]
... | Keyword[public] Keyword[void] identifier[value] operator[SEP] identifier[AjaxRequestTarget] identifier[ajaxRequestTarget] , Keyword[int] identifier[value] operator[SEP] {
identifier[ajaxRequestTarget] operator[SEP] identifier[appendJavaScript] operator[SEP] Keyword[this] operator[SEP] identifier[value] operator... |
public com.google.protobuf.ByteString
getVariableNameBytes() {
java.lang.Object ref = variableName_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
variableName_ = b;
... | class class_name[name] begin[{]
method[getVariableNameBytes, return_type[type[com]], modifier[public], parameter[]] begin[{]
local_variable[type[java], ref]
if[binary_operation[member[.ref], instanceof, type[java]]] begin[{]
local_variable[type[com], b]
... | Keyword[public] identifier[com] operator[SEP] identifier[google] operator[SEP] identifier[protobuf] operator[SEP] identifier[ByteString] identifier[getVariableNameBytes] operator[SEP] operator[SEP] {
identifier[java] operator[SEP] identifier[lang] operator[SEP] identifier[Object] identifier[ref] operator[=] iden... |
private void executeWffBMTask(final byte[] message)
throws UnsupportedEncodingException {
final List<NameValue> nameValues = WffBinaryMessageUtil.VERSION_1
.parse(message);
final NameValue task = nameValues.get(0);
final byte taskValue = task.getValues()[0][0];
... | class class_name[name] begin[{]
method[executeWffBMTask, return_type[void], modifier[private], parameter[message]] begin[{]
local_variable[type[List], nameValues]
local_variable[type[NameValue], task]
local_variable[type[byte], taskValue]
if[binary_operation[call[Task.TA... | Keyword[private] Keyword[void] identifier[executeWffBMTask] operator[SEP] Keyword[final] Keyword[byte] operator[SEP] operator[SEP] identifier[message] operator[SEP] Keyword[throws] identifier[UnsupportedEncodingException] {
Keyword[final] identifier[List] operator[<] identifier[NameValue] operator[>] identifier[... |
private static int lineSeparatorIndex(char[] array, int length) {
for (int k = 0; k < length; k++) {
if (isLineSeparator(array[k])) {
return k;
}
}
return -1;
} | class class_name[name] begin[{]
method[lineSeparatorIndex, return_type[type[int]], modifier[private static], parameter[array, length]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=MethodInvocation(arguments=[MemberReference(member=array, postfix_operators=[], ... | Keyword[private] Keyword[static] Keyword[int] identifier[lineSeparatorIndex] operator[SEP] Keyword[char] operator[SEP] operator[SEP] identifier[array] , Keyword[int] identifier[length] operator[SEP] {
Keyword[for] operator[SEP] Keyword[int] identifier[k] operator[=] Other[0] operator[SEP] identifier[k] operator... |
public static <P extends Enum<P>> JSONObject optJSONObject(final JSONObject json, P e,
boolean emptyForNull) {
JSONObject jsonObject = optJSONObject(json, e);
if (jsonObject == null && emptyForNull) {
jsonObject = EMPTY_OBJECT;
... | class class_name[name] begin[{]
method[optJSONObject, return_type[type[JSONObject]], modifier[public static], parameter[json, e, emptyForNull]] begin[{]
local_variable[type[JSONObject], jsonObject]
if[binary_operation[binary_operation[member[.jsonObject], ==, literal[null]], &&, member[... | Keyword[public] Keyword[static] operator[<] identifier[P] Keyword[extends] identifier[Enum] operator[<] identifier[P] operator[>] operator[>] identifier[JSONObject] identifier[optJSONObject] operator[SEP] Keyword[final] identifier[JSONObject] identifier[json] , identifier[P] identifier[e] , Keyword[boolean] identifie... |
public static <TExpression> BsonField first(final String fieldName, final TExpression expression) {
return accumulator("$first", fieldName, expression);
} | class class_name[name] begin[{]
method[first, return_type[type[BsonField]], modifier[public static], parameter[fieldName, expression]] begin[{]
return[call[.accumulator, parameter[literal["$first"], member[.fieldName], member[.expression]]]]
end[}]
END[}] | Keyword[public] Keyword[static] operator[<] identifier[TExpression] operator[>] identifier[BsonField] identifier[first] operator[SEP] Keyword[final] identifier[String] identifier[fieldName] , Keyword[final] identifier[TExpression] identifier[expression] operator[SEP] {
Keyword[return] identifier[accumulator] op... |
protected String mergeTemplate (String template, Object... data)
throws IOException
{
return mergeTemplate(template, createMap(data));
} | class class_name[name] begin[{]
method[mergeTemplate, return_type[type[String]], modifier[protected], parameter[template, data]] begin[{]
return[call[.mergeTemplate, parameter[member[.template], call[.createMap, parameter[member[.data]]]]]]
end[}]
END[}] | Keyword[protected] identifier[String] identifier[mergeTemplate] operator[SEP] identifier[String] identifier[template] , identifier[Object] operator[...] identifier[data] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[return] identifier[mergeTemplate] operator[SEP] identifier[template] , identi... |
@Override
public void save(T item) {
Serializable idValue = memoryStore.getOrGenerateIdValue(item);
memoryStore.save(idValue, cryptoEntityUtil.encrypt(item));
} | class class_name[name] begin[{]
method[save, return_type[void], modifier[public], parameter[item]] begin[{]
local_variable[type[Serializable], idValue]
call[memoryStore.save, parameter[member[.idValue], call[cryptoEntityUtil.encrypt, parameter[member[.item]]]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[save] operator[SEP] identifier[T] identifier[item] operator[SEP] {
identifier[Serializable] identifier[idValue] operator[=] identifier[memoryStore] operator[SEP] identifier[getOrGenerateIdValue] operator[SEP] identifier[item] operator[SE... |
@Override
public void deleteTrait(String guid, String traitNameToBeDeleted) throws AtlasException {
guid = ParamChecker.notEmpty(guid, "entity id");
traitNameToBeDeleted = ParamChecker.notEmpty(traitNameToBeDeleted, "trait name");
// ensure trait type is already registered w... | class class_name[name] begin[{]
method[deleteTrait, return_type[void], modifier[public], parameter[guid, traitNameToBeDeleted]] begin[{]
assign[member[.guid], call[ParamChecker.notEmpty, parameter[member[.guid], literal["entity id"]]]]
assign[member[.traitNameToBeDeleted], call[... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[deleteTrait] operator[SEP] identifier[String] identifier[guid] , identifier[String] identifier[traitNameToBeDeleted] operator[SEP] Keyword[throws] identifier[AtlasException] {
identifier[guid] operator[=] identifier[ParamChecker] operat... |
protected static Map<String, HttpString> httpStrings() {
final Map<String, HttpString> results = new HashMap<>();
final Class[] classs = {Headers.class, Methods.class, Protocols.class};
for (Class<?> c : classs) {
for (Field field : c.getDeclaredFields()) {
if (field... | class class_name[name] begin[{]
method[httpStrings, return_type[type[Map]], modifier[static protected], parameter[]] begin[{]
local_variable[type[Map], results]
local_variable[type[Class], classs]
ForStatement(body=BlockStatement(label=None, statements=[ForStatement(body=BlockStatement(... | Keyword[protected] Keyword[static] identifier[Map] operator[<] identifier[String] , identifier[HttpString] operator[>] identifier[httpStrings] operator[SEP] operator[SEP] {
Keyword[final] identifier[Map] operator[<] identifier[String] , identifier[HttpString] operator[>] identifier[results] operator[=] Keyword... |
public int read(User registrar) throws IdentityException, InvalidArgumentException {
if (registrar == null) {
throw new InvalidArgumentException("Registrar should be a valid member");
}
String readIdURL = "";
try {
readIdURL = HFCA_IDENTITY + "/" + enrollmentID;
... | class class_name[name] begin[{]
method[read, return_type[type[int]], modifier[public], parameter[registrar]] begin[{]
if[binary_operation[member[.registrar], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_operators... | Keyword[public] Keyword[int] identifier[read] operator[SEP] identifier[User] identifier[registrar] operator[SEP] Keyword[throws] identifier[IdentityException] , identifier[InvalidArgumentException] {
Keyword[if] operator[SEP] identifier[registrar] operator[==] Other[null] operator[SEP] {
Keyword[thro... |
public void afterPropertyChange(String propertyName) {
if(propertyName.startsWith(RtfProperty.CHARACTER)) {
} else {
if(propertyName.startsWith(RtfProperty.PARAGRAPH)) {
} else {
if(propertyName.startsWith(RtfProperty.SECTION)) {
} else {
if(propertyName.startsWith(RtfProperty.DOCUMENT)) {
... | class class_name[name] begin[{]
method[afterPropertyChange, return_type[void], modifier[public], parameter[propertyName]] begin[{]
if[call[propertyName.startsWith, parameter[member[RtfProperty.CHARACTER]]]] begin[{]
else begin[{]
if[call[propertyName.startsWith,... | Keyword[public] Keyword[void] identifier[afterPropertyChange] operator[SEP] identifier[String] identifier[propertyName] operator[SEP] {
Keyword[if] operator[SEP] identifier[propertyName] operator[SEP] identifier[startsWith] operator[SEP] identifier[RtfProperty] operator[SEP] identifier[CHARACTER] operator[SEP] o... |
private void txtBorderWidthFocusLost(java.awt.event.FocusEvent evt) {//GEN-FIRST:event_txtBorderWidthFocusLost
// TODO: the name (and label?) of this text box no longer matches its purpose
if (txtBorderWidth.getText().matches("[0-9]+")) {
quietZoneHorizontal = Integer.parseInt(txtBorderWidth... | class class_name[name] begin[{]
method[txtBorderWidthFocusLost, return_type[void], modifier[private], parameter[evt]] begin[{]
if[call[txtBorderWidth.getText, parameter[]]] begin[{]
assign[member[.quietZoneHorizontal], call[Integer.parseInt, parameter[call[txtBorderWidth... | Keyword[private] Keyword[void] identifier[txtBorderWidthFocusLost] operator[SEP] identifier[java] operator[SEP] identifier[awt] operator[SEP] identifier[event] operator[SEP] identifier[FocusEvent] identifier[evt] operator[SEP] {
Keyword[if] operator[SEP] identifier[txtBorderWidth] operator[SEP] identifier[getTex... |
private void doCollectStats(final TSDB tsdb, final StatsCollector collector,
final boolean canonical) {
collector.addHostTag(canonical);
ConnectionManager.collectStats(collector);
RpcHandler.collectStats(collector);
RpcManager.collectStats(collector);
collectThreadStats(collector);
tsdb.c... | class class_name[name] begin[{]
method[doCollectStats, return_type[void], modifier[private], parameter[tsdb, collector, canonical]] begin[{]
call[collector.addHostTag, parameter[member[.canonical]]]
call[ConnectionManager.collectStats, parameter[member[.collector]]]
... | Keyword[private] Keyword[void] identifier[doCollectStats] operator[SEP] Keyword[final] identifier[TSDB] identifier[tsdb] , Keyword[final] identifier[StatsCollector] identifier[collector] , Keyword[final] Keyword[boolean] identifier[canonical] operator[SEP] {
identifier[collector] operator[SEP] identifier[addHo... |
public static <T> int binarySearch (
T[] array, int offset, int length, Comparable<? super T> key)
{
int low = offset, high = offset+length-1;
while (low <= high) {
int mid = (low + high) >>> 1;
int cmp = key.compareTo(array[mid]);
if (cmp > 0) {
... | class class_name[name] begin[{]
method[binarySearch, return_type[type[int]], modifier[public static], parameter[array, offset, length, key]] begin[{]
local_variable[type[int], low]
while[binary_operation[member[.low], <=, member[.high]]] begin[{]
local_variable[type[int], mi... | Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] Keyword[int] identifier[binarySearch] operator[SEP] identifier[T] operator[SEP] operator[SEP] identifier[array] , Keyword[int] identifier[offset] , Keyword[int] identifier[length] , identifier[Comparable] operator[<] operator[?] Keyword[super] ide... |
public Query resolve(final InternalQName tableName, final boolean includeInheritedTables)
throws InvalidQueryException, RepositoryException
{
final List<Term> terms = new ArrayList<Term>();
Query query = null;
try
{
final String nodeTypeStringName = locationFactory.createJCRN... | class class_name[name] begin[{]
method[resolve, return_type[type[Query]], modifier[public], parameter[tableName, includeInheritedTables]] begin[{]
local_variable[type[List], terms]
local_variable[type[Query], query]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarator... | Keyword[public] identifier[Query] identifier[resolve] operator[SEP] Keyword[final] identifier[InternalQName] identifier[tableName] , Keyword[final] Keyword[boolean] identifier[includeInheritedTables] operator[SEP] Keyword[throws] identifier[InvalidQueryException] , identifier[RepositoryException] {
Keyword[fin... |
public App findApplication(HttpServletRequest req, HttpServletResponse res)
{
ServletApplication application = null;
String strDatatype = BaseHttpTask.getParam(req, DBParams.DATATYPE, null); // Raw data (such as in image from the DB)
if (strDatatype != null) // NOTE: I hope there isn't an... | class class_name[name] begin[{]
method[findApplication, return_type[type[App]], modifier[public], parameter[req, res]] begin[{]
local_variable[type[ServletApplication], application]
local_variable[type[String], strDatatype]
if[binary_operation[member[.strDatatype], !=, literal[n... | Keyword[public] identifier[App] identifier[findApplication] operator[SEP] identifier[HttpServletRequest] identifier[req] , identifier[HttpServletResponse] identifier[res] operator[SEP] {
identifier[ServletApplication] identifier[application] operator[=] Other[null] operator[SEP] identifier[String] identifier[st... |
public void objectTerminated(Object object, Exception e)
{
// Allows to unblock all terminating threads
synchronized (terminatedLock)
{
if (terminated)
{
return;
}
terminated = true;
}
engine.removeTerminationListener(this);
if (streamManager != null)
{
streamManager.removeTermination... | class class_name[name] begin[{]
method[objectTerminated, return_type[void], modifier[public], parameter[object, e]] begin[{]
SYNCHRONIZED[member[.terminatedLock]] BEGIN[{]
if[member[.terminated]] begin[{]
return[None]
else begin[{]
None
... | Keyword[public] Keyword[void] identifier[objectTerminated] operator[SEP] identifier[Object] identifier[object] , identifier[Exception] identifier[e] operator[SEP] {
Keyword[synchronized] operator[SEP] identifier[terminatedLock] operator[SEP] {
Keyword[if] operator[SEP] identifier[terminated] operator... |
public ContentPermissionManager getContentPermissionManager() {
if (contentPermissionManager != null) {
return contentPermissionManager;
}
contentPermissionManager = (ContentPermissionManager) ContainerManager.getComponent("contentPermissionManager");
return contentPermission... | class class_name[name] begin[{]
method[getContentPermissionManager, return_type[type[ContentPermissionManager]], modifier[public], parameter[]] begin[{]
if[binary_operation[member[.contentPermissionManager], !=, literal[null]]] begin[{]
return[member[.contentPermissionManager]]
... | Keyword[public] identifier[ContentPermissionManager] identifier[getContentPermissionManager] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] identifier[contentPermissionManager] operator[!=] Other[null] operator[SEP] {
Keyword[return] identifier[contentPermissionManager] operator[SEP]
}... |
protected HtmlTree getClassUseHeader() {
String cltype = configuration.getText(classdoc.isInterface()?
"doclet.Interface":"doclet.Class");
String clname = classdoc.qualifiedName();
String title = configuration.getText("doclet.Window_ClassUse_Header",
cltype, clname);
... | class class_name[name] begin[{]
method[getClassUseHeader, return_type[type[HtmlTree]], modifier[protected], parameter[]] begin[{]
local_variable[type[String], cltype]
local_variable[type[String], clname]
local_variable[type[String], title]
local_variable[type[HtmlTree], bodyTree... | Keyword[protected] identifier[HtmlTree] identifier[getClassUseHeader] operator[SEP] operator[SEP] {
identifier[String] identifier[cltype] operator[=] identifier[configuration] operator[SEP] identifier[getText] operator[SEP] identifier[classdoc] operator[SEP] identifier[isInterface] operator[SEP] operator[SEP] op... |
public OptionGroupOptionSetting withMinimumEngineVersionPerAllowedValue(MinimumEngineVersionPerAllowedValue... minimumEngineVersionPerAllowedValue) {
if (this.minimumEngineVersionPerAllowedValue == null) {
setMinimumEngineVersionPerAllowedValue(new com.amazonaws.internal.SdkInternalList<MinimumEngin... | class class_name[name] begin[{]
method[withMinimumEngineVersionPerAllowedValue, return_type[type[OptionGroupOptionSetting]], modifier[public], parameter[minimumEngineVersionPerAllowedValue]] begin[{]
if[binary_operation[THIS[member[None.minimumEngineVersionPerAllowedValue]], ==, literal[null]]]... | Keyword[public] identifier[OptionGroupOptionSetting] identifier[withMinimumEngineVersionPerAllowedValue] operator[SEP] identifier[MinimumEngineVersionPerAllowedValue] operator[...] identifier[minimumEngineVersionPerAllowedValue] operator[SEP] {
Keyword[if] operator[SEP] Keyword[this] operator[SEP] identifier[min... |
public static double getLowerBoundForBoverA(final long a, final long b, final double f) {
checkInputs(a, b, f);
if (a == 0) { return 0.0; }
if (f == 1.0) { return (double) b / a; }
return approximateLowerBoundOnP(a, b, NUM_STD_DEVS * hackyAdjuster(f));
} | class class_name[name] begin[{]
method[getLowerBoundForBoverA, return_type[type[double]], modifier[public static], parameter[a, b, f]] begin[{]
call[.checkInputs, parameter[member[.a], member[.b], member[.f]]]
if[binary_operation[member[.a], ==, literal[0]]] begin[{]
... | Keyword[public] Keyword[static] Keyword[double] identifier[getLowerBoundForBoverA] operator[SEP] Keyword[final] Keyword[long] identifier[a] , Keyword[final] Keyword[long] identifier[b] , Keyword[final] Keyword[double] identifier[f] operator[SEP] {
identifier[checkInputs] operator[SEP] identifier[a] , identifi... |
public static long max( long []array , int offset , int length ) {
long max = -Long.MAX_VALUE;
for (int i = 0; i < length; i++) {
long tmp = array[offset+i];
if( tmp > max ) {
max = tmp;
}
}
return max;
} | class class_name[name] begin[{]
method[max, return_type[type[long]], modifier[public static], parameter[array, offset, length]] begin[{]
local_variable[type[long], max]
ForStatement(body=BlockStatement(label=None, statements=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclara... | Keyword[public] Keyword[static] Keyword[long] identifier[max] operator[SEP] Keyword[long] operator[SEP] operator[SEP] identifier[array] , Keyword[int] identifier[offset] , Keyword[int] identifier[length] operator[SEP] {
Keyword[long] identifier[max] operator[=] operator[-] identifier[Long] operator[SEP] identi... |
public HttpHealthCheckedEndpointGroup build() {
return new HttpHealthCheckedEndpointGroup(clientFactory, delegate, protocol, healthCheckPath,
healthCheckPort, retryInterval, configurator);
} | class class_name[name] begin[{]
method[build, return_type[type[HttpHealthCheckedEndpointGroup]], modifier[public], parameter[]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=clientFactory, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MemberReference(member=dele... | Keyword[public] identifier[HttpHealthCheckedEndpointGroup] identifier[build] operator[SEP] operator[SEP] {
Keyword[return] Keyword[new] identifier[HttpHealthCheckedEndpointGroup] operator[SEP] identifier[clientFactory] , identifier[delegate] , identifier[protocol] , identifier[healthCheckPath] , identifier[h... |
@Override
public DeleteDatastoreResult deleteDatastore(DeleteDatastoreRequest request) {
request = beforeClientExecution(request);
return executeDeleteDatastore(request);
} | class class_name[name] begin[{]
method[deleteDatastore, return_type[type[DeleteDatastoreResult]], modifier[public], parameter[request]] begin[{]
assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]]
return[call[.executeDeleteDatastore, parameter[member[.req... | annotation[@] identifier[Override] Keyword[public] identifier[DeleteDatastoreResult] identifier[deleteDatastore] operator[SEP] identifier[DeleteDatastoreRequest] identifier[request] operator[SEP] {
identifier[request] operator[=] identifier[beforeClientExecution] operator[SEP] identifier[request] operator[SEP] o... |
public MultiFileResource add(File... files) {
for (File file : files) {
this.add(new FileResource(file));
}
return this;
} | class class_name[name] begin[{]
method[add, return_type[type[MultiFileResource]], modifier[public], parameter[files]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=This(postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[MethodInvocat... | Keyword[public] identifier[MultiFileResource] identifier[add] operator[SEP] identifier[File] operator[...] identifier[files] operator[SEP] {
Keyword[for] operator[SEP] identifier[File] identifier[file] operator[:] identifier[files] operator[SEP] {
Keyword[this] operator[SEP] identifier[add] operator[... |
@SuppressWarnings({"unchecked"})
public static <T> T read(InputStream jsonInputStream, String jsonPath, Predicate... filters) throws IOException {
return new ParseContextImpl().parse(jsonInputStream).read(jsonPath, filters);
} | class class_name[name] begin[{]
method[read, return_type[type[T]], modifier[public static], parameter[jsonInputStream, jsonPath, filters]] begin[{]
return[ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_operators=[], qualifier=None, selectors=[MethodI... | annotation[@] identifier[SuppressWarnings] operator[SEP] {
literal[String]
} operator[SEP] Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[T] identifier[read] operator[SEP] identifier[InputStream] identifier[jsonInputStream] , identifier[String] identifier[jsonPath] , identi... |
public static LanguageExtension findFirst(Collection<? extends Extension> extensions)
{
for (Extension extension : extensions)
{
if (LANGUAGE_EXTENSION_ID == extension.getId())
return (LanguageExtension)extension;
}
return null;
} | class class_name[name] begin[{]
method[findFirst, return_type[type[LanguageExtension]], modifier[public static], parameter[extensions]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[IfStatement(condition=BinaryOperation(operandl=MemberReference(member=LANGUAGE_EXTENSION_ID, postfix_... | Keyword[public] Keyword[static] identifier[LanguageExtension] identifier[findFirst] operator[SEP] identifier[Collection] operator[<] operator[?] Keyword[extends] identifier[Extension] operator[>] identifier[extensions] operator[SEP] {
Keyword[for] operator[SEP] identifier[Extension] identifier[extension] operato... |
public List<byte[]> lookup() {
try {
return lookupAsync().join();
} catch (InterruptedException e) {
LOG.error("Interrupted performing lookup", e);
Thread.currentThread().interrupt();
return null;
} catch (DeferredGroupException e) {
final Throwable ex = Exceptions.getCause(e);... | class class_name[name] begin[{]
method[lookup, return_type[type[List]], modifier[public], parameter[]] begin[{]
TryStatement(block=[ReturnStatement(expression=MethodInvocation(arguments=[], member=lookupAsync, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[MethodInvocation(arguments=... | Keyword[public] identifier[List] operator[<] Keyword[byte] operator[SEP] operator[SEP] operator[>] identifier[lookup] operator[SEP] operator[SEP] {
Keyword[try] {
Keyword[return] identifier[lookupAsync] operator[SEP] operator[SEP] operator[SEP] identifier[join] operator[SEP] operator[SEP] operator[SEP... |
public String replace(String content, String selector, String replacement) {
return replaceAll(content, Collections.singletonMap(selector, replacement));
} | class class_name[name] begin[{]
method[replace, return_type[type[String]], modifier[public], parameter[content, selector, replacement]] begin[{]
return[call[.replaceAll, parameter[member[.content], call[Collections.singletonMap, parameter[member[.selector], member[.replacement]]]]]]
end[}]
END[}] | Keyword[public] identifier[String] identifier[replace] operator[SEP] identifier[String] identifier[content] , identifier[String] identifier[selector] , identifier[String] identifier[replacement] operator[SEP] {
Keyword[return] identifier[replaceAll] operator[SEP] identifier[content] , identifier[Collections] ... |
public long time(final Stat name) {
name.requiresTimer();
final Stopwatch stopwatch = tracker.getTimers().get(name);
return stopwatch == null ? 0 : stopwatch.elapsed(TimeUnit.MILLISECONDS);
} | class class_name[name] begin[{]
method[time, return_type[type[long]], modifier[public], parameter[name]] begin[{]
call[name.requiresTimer, parameter[]]
local_variable[type[Stopwatch], stopwatch]
return[TernaryExpression(condition=BinaryOperation(operandl=MemberReference(member=s... | Keyword[public] Keyword[long] identifier[time] operator[SEP] Keyword[final] identifier[Stat] identifier[name] operator[SEP] {
identifier[name] operator[SEP] identifier[requiresTimer] operator[SEP] operator[SEP] operator[SEP] Keyword[final] identifier[Stopwatch] identifier[stopwatch] operator[=] identifier[tracke... |
public static PathMappingResult of(String path, @Nullable String query) {
return of(path, query, ImmutableMap.of());
} | class class_name[name] begin[{]
method[of, return_type[type[PathMappingResult]], modifier[public static], parameter[path, query]] begin[{]
return[call[.of, parameter[member[.path], member[.query], call[ImmutableMap.of, parameter[]]]]]
end[}]
END[}] | Keyword[public] Keyword[static] identifier[PathMappingResult] identifier[of] operator[SEP] identifier[String] identifier[path] , annotation[@] identifier[Nullable] identifier[String] identifier[query] operator[SEP] {
Keyword[return] identifier[of] operator[SEP] identifier[path] , identifier[query] , identifie... |
@Override
public void putContext(@SuppressWarnings("rawtypes") Class key,
Object contextObject) {
if (wrappedContext == null) {
super.putContext(key, contextObject);
} else {
wrappedContext.putContext(key, contextObject);
}
} | class class_name[name] begin[{]
method[putContext, return_type[void], modifier[public], parameter[key, contextObject]] begin[{]
if[binary_operation[member[.wrappedContext], ==, literal[null]]] begin[{]
SuperMethodInvocation(arguments=[MemberReference(member=key, postfix_... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[putContext] operator[SEP] annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] identifier[Class] identifier[key] , identifier[Object] identifier[contextObject] operator[SEP] {
Keyword[if] operator[SEP] ... |
@Override
public void enlargeFile(long toEnlarge) throws IOException {
size += (long) Math.ceil((double) toEnlarge / incrementSize) * incrementSize;
logger.debug("Enlarge filesize of {} to {}", osFile, size);
contentEnd = size;
accessFile.setLength(size);
// TODO check buffe... | class class_name[name] begin[{]
method[enlargeFile, return_type[void], modifier[public], parameter[toEnlarge]] begin[{]
assign[member[.size], binary_operation[Cast(expression=MethodInvocation(arguments=[BinaryOperation(operandl=Cast(expression=MemberReference(member=toEnlarge, postfix_operators... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[enlargeFile] operator[SEP] Keyword[long] identifier[toEnlarge] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[size] operator[+=] operator[SEP] Keyword[long] operator[SEP] identifier[Math] operator[SEP] identifier[ceil... |
public MustacheEngineBuilder addResolver(Resolver resolver) {
checkArgumentNotNull(resolver);
checkNotBuilt();
this.resolvers.add(resolver);
return this;
} | class class_name[name] begin[{]
method[addResolver, return_type[type[MustacheEngineBuilder]], modifier[public], parameter[resolver]] begin[{]
call[.checkArgumentNotNull, parameter[member[.resolver]]]
call[.checkNotBuilt, parameter[]]
THIS[member[None.resolvers]ca... | Keyword[public] identifier[MustacheEngineBuilder] identifier[addResolver] operator[SEP] identifier[Resolver] identifier[resolver] operator[SEP] {
identifier[checkArgumentNotNull] operator[SEP] identifier[resolver] operator[SEP] operator[SEP] identifier[checkNotBuilt] operator[SEP] operator[SEP] operator[SEP] Key... |
public ElementDefinitionDt setRepresentation(java.util.List<BoundCodeDt<PropertyRepresentationEnum>> theValue) {
myRepresentation = theValue;
return this;
} | class class_name[name] begin[{]
method[setRepresentation, return_type[type[ElementDefinitionDt]], modifier[public], parameter[theValue]] begin[{]
assign[member[.myRepresentation], member[.theValue]]
return[THIS[]]
end[}]
END[}] | Keyword[public] identifier[ElementDefinitionDt] identifier[setRepresentation] operator[SEP] identifier[java] operator[SEP] identifier[util] operator[SEP] identifier[List] operator[<] identifier[BoundCodeDt] operator[<] identifier[PropertyRepresentationEnum] operator[>] operator[>] identifier[theValue] operator[SEP] {
... |
public static Calendar previousInterval(final long ts, final int interval,
final int unit, final TimeZone tz) {
if (ts < 0) {
throw new IllegalArgumentException("Timestamp cannot be less than zero");
}
if (interval < 1) {
throw new IllegalArgumentException("Interval must be greater than z... | class class_name[name] begin[{]
method[previousInterval, return_type[type[Calendar]], modifier[public static], parameter[ts, interval, unit, tz]] begin[{]
if[binary_operation[member[.ts], <, literal[0]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_oper... | Keyword[public] Keyword[static] identifier[Calendar] identifier[previousInterval] operator[SEP] Keyword[final] Keyword[long] identifier[ts] , Keyword[final] Keyword[int] identifier[interval] , Keyword[final] Keyword[int] identifier[unit] , Keyword[final] identifier[TimeZone] identifier[tz] operator[SEP] {
Key... |
@NonNull
public RequestCreator resizeDimen(int targetWidthResId, int targetHeightResId) {
Resources resources = picasso.context.getResources();
int targetWidth = resources.getDimensionPixelSize(targetWidthResId);
int targetHeight = resources.getDimensionPixelSize(targetHeightResId);
return resize(targ... | class class_name[name] begin[{]
method[resizeDimen, return_type[type[RequestCreator]], modifier[public], parameter[targetWidthResId, targetHeightResId]] begin[{]
local_variable[type[Resources], resources]
local_variable[type[int], targetWidth]
local_variable[type[int], targetHeight]
... | annotation[@] identifier[NonNull] Keyword[public] identifier[RequestCreator] identifier[resizeDimen] operator[SEP] Keyword[int] identifier[targetWidthResId] , Keyword[int] identifier[targetHeightResId] operator[SEP] {
identifier[Resources] identifier[resources] operator[=] identifier[picasso] operator[SEP] iden... |
public Iterator<V> valueIterator(@SuppressWarnings("unused") K name) {
List<V> empty = Collections.emptyList();
return empty.iterator();
} | class class_name[name] begin[{]
method[valueIterator, return_type[type[Iterator]], modifier[public], parameter[name]] begin[{]
local_variable[type[List], empty]
return[call[empty.iterator, parameter[]]]
end[}]
END[}] | Keyword[public] identifier[Iterator] operator[<] identifier[V] operator[>] identifier[valueIterator] operator[SEP] annotation[@] identifier[SuppressWarnings] operator[SEP] literal[String] operator[SEP] identifier[K] identifier[name] operator[SEP] {
identifier[List] operator[<] identifier[V] operator[>] identifie... |
protected int levelOffset(Context context) {
//TODO: Unused method, make sure this is never used and then remove it.
int levelOffset;
switch (context.position) {
case DOCUMENT_BEFORE:
case DOCUMENT_AFTER:
levelOffset = 0;
break;
... | class class_name[name] begin[{]
method[levelOffset, return_type[type[int]], modifier[protected], parameter[context]] begin[{]
local_variable[type[int], levelOffset]
SwitchStatement(cases=[SwitchStatementCase(case=['DOCUMENT_BEFORE', 'DOCUMENT_AFTER'], statements=[StatementExpression(expression=... | Keyword[protected] Keyword[int] identifier[levelOffset] operator[SEP] identifier[Context] identifier[context] operator[SEP] {
Keyword[int] identifier[levelOffset] operator[SEP] Keyword[switch] operator[SEP] identifier[context] operator[SEP] identifier[position] operator[SEP] {
Keyword[case] identifier... |
public ArrayList<File> getFiles() {
//TODO Why ArrayList, change to list when in a proper IDE
final JsArray<FileJS> filesJS = getFilesNative(getElement());
final ArrayList<File> files = new ArrayList<File>();
if (filesJS != null) {
for (int i = 0; i < filesJS.length(); i++) {
files.add(filesJS.get(i));... | class class_name[name] begin[{]
method[getFiles, return_type[type[ArrayList]], modifier[public], parameter[]] begin[{]
local_variable[type[JsArray], filesJS]
local_variable[type[ArrayList], files]
if[binary_operation[member[.filesJS], !=, literal[null]]] begin[{]
For... | Keyword[public] identifier[ArrayList] operator[<] identifier[File] operator[>] identifier[getFiles] operator[SEP] operator[SEP] {
Keyword[final] identifier[JsArray] operator[<] identifier[FileJS] operator[>] identifier[filesJS] operator[=] identifier[getFilesNative] operator[SEP] identifier[getElement] operator[... |
public static void runExample(
AdManagerServices adManagerServices, AdManagerSession session, long customFieldId)
throws RemoteException {
// Get the CustomFieldService.
CustomFieldServiceInterface customFieldService =
adManagerServices.get(session, CustomFieldServiceInterface.class);
/... | class class_name[name] begin[{]
method[runExample, return_type[void], modifier[public static], parameter[adManagerServices, session, customFieldId]] begin[{]
local_variable[type[CustomFieldServiceInterface], customFieldService]
local_variable[type[StatementBuilder], statementBuilder]
lo... | Keyword[public] Keyword[static] Keyword[void] identifier[runExample] operator[SEP] identifier[AdManagerServices] identifier[adManagerServices] , identifier[AdManagerSession] identifier[session] , Keyword[long] identifier[customFieldId] operator[SEP] Keyword[throws] identifier[RemoteException] {
identifier[Cust... |
public GetArtistRequest.Builder getArtist(String id) {
return new GetArtistRequest.Builder(accessToken)
.setDefaults(httpManager, scheme, host, port)
.id(id);
} | class class_name[name] begin[{]
method[getArtist, return_type[type[GetArtistRequest]], modifier[public], parameter[id]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=accessToken, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[])], body=None, constructor_type_argument... | Keyword[public] identifier[GetArtistRequest] operator[SEP] identifier[Builder] identifier[getArtist] operator[SEP] identifier[String] identifier[id] operator[SEP] {
Keyword[return] Keyword[new] identifier[GetArtistRequest] operator[SEP] identifier[Builder] operator[SEP] identifier[accessToken] operator[SEP] oper... |
public static void stdDev(Planar<GrayU8> input, GrayU8 output, @Nullable GrayU8 avg) {
stdDev(input,output,avg,0,input.getNumBands() - 1);
} | class class_name[name] begin[{]
method[stdDev, return_type[void], modifier[public static], parameter[input, output, avg]] begin[{]
call[.stdDev, parameter[member[.input], member[.output], member[.avg], literal[0], binary_operation[call[input.getNumBands, parameter[]], -, literal[1]]]]
end[}... | Keyword[public] Keyword[static] Keyword[void] identifier[stdDev] operator[SEP] identifier[Planar] operator[<] identifier[GrayU8] operator[>] identifier[input] , identifier[GrayU8] identifier[output] , annotation[@] identifier[Nullable] identifier[GrayU8] identifier[avg] operator[SEP] {
identifier[stdDev] opera... |
private boolean tryAddModule(
IAggregator aggregator,
List<String> list,
String bundleRoot,
IResource bundleRootRes,
String locale,
String resource,
Collection<String> availableLocales)
throws IOException {
if (availableLocales != null && !availableLocales.contains(locale)) {
re... | class class_name[name] begin[{]
method[tryAddModule, return_type[type[boolean]], modifier[private], parameter[aggregator, list, bundleRoot, bundleRootRes, locale, resource, availableLocales]] begin[{]
if[binary_operation[binary_operation[member[.availableLocales], !=, literal[null]], &&, call[a... | Keyword[private] Keyword[boolean] identifier[tryAddModule] operator[SEP] identifier[IAggregator] identifier[aggregator] , identifier[List] operator[<] identifier[String] operator[>] identifier[list] , identifier[String] identifier[bundleRoot] , identifier[IResource] identifier[bundleRootRes] , identifier[String] id... |
public void addLast(E e) {
if (e == null)
throw new NullPointerException();
elements[tail] = e;
if ( (tail = (tail + 1) & (elements.length - 1)) == head)
doubleCapacity();
} | class class_name[name] begin[{]
method[addLast, return_type[void], modifier[public], parameter[e]] begin[{]
if[binary_operation[member[.e], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_... | Keyword[public] Keyword[void] identifier[addLast] operator[SEP] identifier[E] identifier[e] operator[SEP] {
Keyword[if] operator[SEP] identifier[e] operator[==] Other[null] operator[SEP] Keyword[throw] Keyword[new] identifier[NullPointerException] operator[SEP] operator[SEP] operator[SEP] identifier[elements] op... |
@SafeVarargs
public static long[] removeAll(final long[] a, final long... elements) {
if (N.isNullOrEmpty(a)) {
return N.EMPTY_LONG_ARRAY;
} else if (N.isNullOrEmpty(elements)) {
return a.clone();
} else if (elements.length == 1) {
return removeAllO... | class class_name[name] begin[{]
method[removeAll, return_type[type[long]], modifier[public static], parameter[a, elements]] begin[{]
if[call[N.isNullOrEmpty, parameter[member[.a]]]] begin[{]
return[member[N.EMPTY_LONG_ARRAY]]
else begin[{]
if[call[N.isNullOrEmpty... | annotation[@] identifier[SafeVarargs] Keyword[public] Keyword[static] Keyword[long] operator[SEP] operator[SEP] identifier[removeAll] operator[SEP] Keyword[final] Keyword[long] operator[SEP] operator[SEP] identifier[a] , Keyword[final] Keyword[long] operator[...] identifier[elements] operator[SEP] {
Keyword[if]... |
public Set<ConstraintViolation> validate(DataSetInfo info) {
Set<ConstraintViolation> errors = new LinkedHashSet<ConstraintViolation>();
try {
if (info.isMandatory() && get(info.getDataSetNumber()) == null) {
errors.add(new ConstraintViolation(info, ConstraintViolation.MANDATORY_MISSING));
}
if (... | class class_name[name] begin[{]
method[validate, return_type[type[Set]], modifier[public], parameter[info]] begin[{]
local_variable[type[Set], errors]
TryStatement(block=[IfStatement(condition=BinaryOperation(operandl=MethodInvocation(arguments=[], member=isMandatory, postfix_operators=[], pref... | Keyword[public] identifier[Set] operator[<] identifier[ConstraintViolation] operator[>] identifier[validate] operator[SEP] identifier[DataSetInfo] identifier[info] operator[SEP] {
identifier[Set] operator[<] identifier[ConstraintViolation] operator[>] identifier[errors] operator[=] Keyword[new] identifier[Linked... |
public JwwfServer startAndJoin() {
try {
server.start();
server.join();
} catch (Exception e) {
e.printStackTrace();
}
return this;
} | class class_name[name] begin[{]
method[startAndJoin, return_type[type[JwwfServer]], modifier[public], parameter[]] begin[{]
TryStatement(block=[StatementExpression(expression=MethodInvocation(arguments=[], member=start, postfix_operators=[], prefix_operators=[], qualifier=server, selectors=[], type_arg... | Keyword[public] identifier[JwwfServer] identifier[startAndJoin] operator[SEP] operator[SEP] {
Keyword[try] {
identifier[server] operator[SEP] identifier[start] operator[SEP] operator[SEP] operator[SEP] identifier[server] operator[SEP] identifier[join] operator[SEP] operator[SEP] operator[SEP]
}... |
@Override
public void prepareInsert(final SQLInsert _insert,
final Attribute _attribute,
final Object... _values)
throws SQLException
{
checkSQLColumnSize(_attribute, 1);
try {
_insert.column(_attribute.getSqlColName... | class class_name[name] begin[{]
method[prepareInsert, return_type[void], modifier[public], parameter[_insert, _attribute, _values]] begin[{]
call[.checkSQLColumnSize, parameter[member[._attribute], literal[1]]]
TryStatement(block=[StatementExpression(expression=MethodInvocation(argument... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[prepareInsert] operator[SEP] Keyword[final] identifier[SQLInsert] identifier[_insert] , Keyword[final] identifier[Attribute] identifier[_attribute] , Keyword[final] identifier[Object] operator[...] identifier[_values] operator[SEP] Keyword[th... |
private static <T> void updateAppLinkDataTable(Map<String, Set<T>> table,
boolean add,
String key,
T value,
String t... | class class_name[name] begin[{]
method[updateAppLinkDataTable, return_type[void], modifier[private static], parameter[table, add, key, value, tracePrefix]] begin[{]
local_variable[type[boolean], isTraceOn]
local_variable[type[Set], values]
if[member[.add]] begin[{]
... | Keyword[private] Keyword[static] operator[<] identifier[T] operator[>] Keyword[void] identifier[updateAppLinkDataTable] operator[SEP] identifier[Map] operator[<] identifier[String] , identifier[Set] operator[<] identifier[T] operator[>] operator[>] identifier[table] , Keyword[boolean] identifier[add] , identifier[St... |
public static boolean sameDimensions(Matrix A, Matrix B)
{
return A.rows() == B.rows() && A.cols() == B.cols();
} | class class_name[name] begin[{]
method[sameDimensions, return_type[type[boolean]], modifier[public static], parameter[A, B]] begin[{]
return[binary_operation[binary_operation[call[A.rows, parameter[]], ==, call[B.rows, parameter[]]], &&, binary_operation[call[A.cols, parameter[]], ==, call[B.cols, para... | Keyword[public] Keyword[static] Keyword[boolean] identifier[sameDimensions] operator[SEP] identifier[Matrix] identifier[A] , identifier[Matrix] identifier[B] operator[SEP] {
Keyword[return] identifier[A] operator[SEP] identifier[rows] operator[SEP] operator[SEP] operator[==] identifier[B] operator[SEP] identifi... |
public void putNextEntry(ZipEntry e) throws IOException {
ensureOpen();
if (current != null) {
closeEntry(); // close previous entry
}
if (e.time == -1) {
e.setTime(System.currentTimeMillis());
}
if (e.method == -1) {
e.method = m... | class class_name[name] begin[{]
method[putNextEntry, return_type[void], modifier[public], parameter[e]] begin[{]
call[.ensureOpen, parameter[]]
if[binary_operation[member[.current], !=, literal[null]]] begin[{]
call[.closeEntry, parameter[]]
else ... | Keyword[public] Keyword[void] identifier[putNextEntry] operator[SEP] identifier[ZipEntry] identifier[e] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[ensureOpen] operator[SEP] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[current] operator[!=] Other[null] operator[SEP] {
... |
public void marshall(Robot robot, ProtocolMarshaller protocolMarshaller) {
if (robot == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(robot.getArn(), ARN_BINDING);
protocolMarshaller.mar... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[robot, protocolMarshaller]] begin[{]
if[binary_operation[member[.robot], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefi... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[Robot] identifier[robot] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[robot] operator[==] Other[null] operator[SEP] {
Keyword[throw] Keyword[new] identif... |
public static int getTurns(final AdjacencyGraph adjacencyGraph, final String part)
{
int direction = 0;
int turns = 1;
char[] parts = part.toCharArray();
for (int i1 = 0; i1 < parts.length; i1++)
{
Character character = parts[i1];
if (i1 + 1 >= parts.... | class class_name[name] begin[{]
method[getTurns, return_type[type[int]], modifier[public static], parameter[adjacencyGraph, part]] begin[{]
local_variable[type[int], direction]
local_variable[type[int], turns]
local_variable[type[char], parts]
ForStatement(body=BlockStatement(la... | Keyword[public] Keyword[static] Keyword[int] identifier[getTurns] operator[SEP] Keyword[final] identifier[AdjacencyGraph] identifier[adjacencyGraph] , Keyword[final] identifier[String] identifier[part] operator[SEP] {
Keyword[int] identifier[direction] operator[=] Other[0] operator[SEP] Keyword[int] identifier[... |
public int read(char []buffer, int offset, int length)
throws IOException
{
byte[] bytes = new byte[length];
int count = _file.read(bytes, 0, length);
for (int i = 0; i < count; i++) {
buffer[offset + i] = (char) bytes[i];
}
return count;
} | class class_name[name] begin[{]
method[read, return_type[type[int]], modifier[public], parameter[buffer, offset, length]] begin[{]
local_variable[type[byte], bytes]
local_variable[type[int], count]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=A... | Keyword[public] Keyword[int] identifier[read] operator[SEP] Keyword[char] operator[SEP] operator[SEP] identifier[buffer] , Keyword[int] identifier[offset] , Keyword[int] identifier[length] operator[SEP] Keyword[throws] identifier[IOException] {
Keyword[byte] operator[SEP] operator[SEP] identifier[bytes] operat... |
public void marshall(InferenceSpecification inferenceSpecification, ProtocolMarshaller protocolMarshaller) {
if (inferenceSpecification == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(inferenceSpec... | class class_name[name] begin[{]
method[marshall, return_type[void], modifier[public], parameter[inferenceSpecification, protocolMarshaller]] begin[{]
if[binary_operation[member[.inferenceSpecification], ==, literal[null]]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[L... | Keyword[public] Keyword[void] identifier[marshall] operator[SEP] identifier[InferenceSpecification] identifier[inferenceSpecification] , identifier[ProtocolMarshaller] identifier[protocolMarshaller] operator[SEP] {
Keyword[if] operator[SEP] identifier[inferenceSpecification] operator[==] Other[null] operator[SE... |
public ClassInfoList getAnnotations() {
if (!scanResult.scanSpec.enableAnnotationInfo) {
throw new IllegalArgumentException("Please call ClassGraph#enableAnnotationInfo() before #scan()");
}
// Get all annotations on this class
final ReachableAndDirectlyRelatedClasses annota... | class class_name[name] begin[{]
method[getAnnotations, return_type[type[ClassInfoList]], modifier[public], parameter[]] begin[{]
if[member[scanResult.scanSpec.enableAnnotationInfo]] begin[{]
ThrowStatement(expression=ClassCreator(arguments=[Literal(postfix_operators=[], prefix_opera... | Keyword[public] identifier[ClassInfoList] identifier[getAnnotations] operator[SEP] operator[SEP] {
Keyword[if] operator[SEP] operator[!] identifier[scanResult] operator[SEP] identifier[scanSpec] operator[SEP] identifier[enableAnnotationInfo] operator[SEP] {
Keyword[throw] Keyword[new] identifier[Illeg... |
public String getTableNames(boolean bAddQuotes, Map<String, Object> properties)
{
String strString = "";
strString += this.getLeftRecord().getTableNames(bAddQuotes);
String strOn = "ON";
switch (m_JoinType)
{
case DBConstants.LEFT_INNER:
if (properties.get... | class class_name[name] begin[{]
method[getTableNames, return_type[type[String]], modifier[public], parameter[bAddQuotes, properties]] begin[{]
local_variable[type[String], strString]
assign[member[.strString], THIS[call[None.getLeftRecord, parameter[]]call[None.getTableNames, parameter[... | Keyword[public] identifier[String] identifier[getTableNames] operator[SEP] Keyword[boolean] identifier[bAddQuotes] , identifier[Map] operator[<] identifier[String] , identifier[Object] operator[>] identifier[properties] operator[SEP] {
identifier[String] identifier[strString] operator[=] literal[String] operat... |
@GwtIncompatible("NavigableMap")
public static <K, V> NavigableMap<K, V> synchronizedNavigableMap(
NavigableMap<K, V> navigableMap) {
return Synchronized.navigableMap(navigableMap);
} | class class_name[name] begin[{]
method[synchronizedNavigableMap, return_type[type[NavigableMap]], modifier[public static], parameter[navigableMap]] begin[{]
return[call[Synchronized.navigableMap, parameter[member[.navigableMap]]]]
end[}]
END[}] | annotation[@] identifier[GwtIncompatible] operator[SEP] literal[String] operator[SEP] Keyword[public] Keyword[static] operator[<] identifier[K] , identifier[V] operator[>] identifier[NavigableMap] operator[<] identifier[K] , identifier[V] operator[>] identifier[synchronizedNavigableMap] operator[SEP] identifier[Navig... |
public static <T> Level0IndefiniteArrayOperator<T[],T> onArray(final T[] target) {
return new Level0IndefiniteArrayOperator<T[],T>(ExecutionTarget.forOp(target, Normalisation.NONE));
} | class class_name[name] begin[{]
method[onArray, return_type[type[Level0IndefiniteArrayOperator]], modifier[public static], parameter[target]] begin[{]
return[ClassCreator(arguments=[MethodInvocation(arguments=[MemberReference(member=target, postfix_operators=[], prefix_operators=[], qualifier=, selecto... | Keyword[public] Keyword[static] operator[<] identifier[T] operator[>] identifier[Level0IndefiniteArrayOperator] operator[<] identifier[T] operator[SEP] operator[SEP] , identifier[T] operator[>] identifier[onArray] operator[SEP] Keyword[final] identifier[T] operator[SEP] operator[SEP] identifier[target] operator[SEP] ... |
private void updateSkinMappingUsingTypeLocaleSkin(ResourceBrowser rsBrowser, JawrConfig config,
Map<String, Map<String, VariantSet>> skinMapping, Set<String> skinRootDirectories) {
String defaultSkinName = null;
String defaultLocaleName = null;
// Check if there are no directory which is contained in another... | class class_name[name] begin[{]
method[updateSkinMappingUsingTypeLocaleSkin, return_type[void], modifier[private], parameter[rsBrowser, config, skinMapping, skinRootDirectories]] begin[{]
local_variable[type[String], defaultSkinName]
local_variable[type[String], defaultLocaleName]
ForSt... | Keyword[private] Keyword[void] identifier[updateSkinMappingUsingTypeLocaleSkin] operator[SEP] identifier[ResourceBrowser] identifier[rsBrowser] , identifier[JawrConfig] identifier[config] , identifier[Map] operator[<] identifier[String] , identifier[Map] operator[<] identifier[String] , identifier[VariantSet] opera... |
public void removeConnectionEventListener(ConnectionEventListener listener) {
log.finest("removeConnectionEventListener()");
if (listener == null)
throw new IllegalArgumentException("Listener is null");
listeners.remove(listener);
} | class class_name[name] begin[{]
method[removeConnectionEventListener, return_type[void], modifier[public], parameter[listener]] begin[{]
call[log.finest, parameter[literal["removeConnectionEventListener()"]]]
if[binary_operation[member[.listener], ==, literal[null]]] begin[{]
Th... | Keyword[public] Keyword[void] identifier[removeConnectionEventListener] operator[SEP] identifier[ConnectionEventListener] identifier[listener] operator[SEP] {
identifier[log] operator[SEP] identifier[finest] operator[SEP] literal[String] operator[SEP] operator[SEP] Keyword[if] operator[SEP] identifier[listener] ... |
public static void populateAttributes(final UIComponent component,
final FacesCell fcell,
final Map<String, Map<String, String>> defaultControlMap) {
List<CellFormAttributes> inputAttrs = fcell.getInputAttrs();
String cname = findComponentNameFromClass(component);
if (cname == null) {
return;
... | class class_name[name] begin[{]
method[populateAttributes, return_type[void], modifier[public static], parameter[component, fcell, defaultControlMap]] begin[{]
local_variable[type[List], inputAttrs]
local_variable[type[String], cname]
if[binary_operation[member[.cname], ==, lite... | Keyword[public] Keyword[static] Keyword[void] identifier[populateAttributes] operator[SEP] Keyword[final] identifier[UIComponent] identifier[component] , Keyword[final] identifier[FacesCell] identifier[fcell] , Keyword[final] identifier[Map] operator[<] identifier[String] , identifier[Map] operator[<] identifier[Str... |
public DAPNode cloneDAG(CloneMap map)
throws CloneNotSupportedException
{
AttributeTable at = (AttributeTable) super.cloneDAG(map);
at._attr = new SortedTable();
for (int i = 0; i < _attr.size(); i++) {
String key = (String) _attr.getKey(i);
... | class class_name[name] begin[{]
method[cloneDAG, return_type[type[DAPNode]], modifier[public], parameter[map]] begin[{]
local_variable[type[AttributeTable], at]
assign[member[at._attr], ClassCreator(arguments=[], body=None, constructor_type_arguments=None, postfix_operators=[], prefix_o... | Keyword[public] identifier[DAPNode] identifier[cloneDAG] operator[SEP] identifier[CloneMap] identifier[map] operator[SEP] Keyword[throws] identifier[CloneNotSupportedException] {
identifier[AttributeTable] identifier[at] operator[=] operator[SEP] identifier[AttributeTable] operator[SEP] Keyword[super] operator[S... |
public static String enc(String in) {
if (in == null || in.isEmpty()) {
return "";
}
StringBuilder out = new StringBuilder();
enc(in, out);
return out.toString();
} | class class_name[name] begin[{]
method[enc, return_type[type[String]], modifier[public static], parameter[in]] begin[{]
if[binary_operation[binary_operation[member[.in], ==, literal[null]], ||, call[in.isEmpty, parameter[]]]] begin[{]
return[literal[""]]
else begin[{]
None
... | Keyword[public] Keyword[static] identifier[String] identifier[enc] operator[SEP] identifier[String] identifier[in] operator[SEP] {
Keyword[if] operator[SEP] identifier[in] operator[==] Other[null] operator[||] identifier[in] operator[SEP] identifier[isEmpty] operator[SEP] operator[SEP] operator[SEP] {
... |
@NonNull public <T> T peek(int index) {
//noinspection unchecked
return (T) history.get(history.size() - index - 1);
} | class class_name[name] begin[{]
method[peek, return_type[type[T]], modifier[public], parameter[index]] begin[{]
return[Cast(expression=MethodInvocation(arguments=[BinaryOperation(operandl=BinaryOperation(operandl=MethodInvocation(arguments=[], member=size, postfix_operators=[], prefix_operators=[], qua... | annotation[@] identifier[NonNull] Keyword[public] operator[<] identifier[T] operator[>] identifier[T] identifier[peek] operator[SEP] Keyword[int] identifier[index] operator[SEP] {
Keyword[return] operator[SEP] identifier[T] operator[SEP] identifier[history] operator[SEP] identifier[get] operator[SEP] identifier[... |
public static Map<String, Set<InetAddress>> getNetworkInterfaceAddresses(boolean includeLoopback) {
//JVM returns interfaces in a non-predictable order, so to make this more predictable
//let's have them sort by interface name (by using a TreeMap).
Map<String, Set<InetAddress>> interfaceAddressM... | class class_name[name] begin[{]
method[getNetworkInterfaceAddresses, return_type[type[Map]], modifier[public static], parameter[includeLoopback]] begin[{]
local_variable[type[Map], interfaceAddressMap]
TryStatement(block=[LocalVariableDeclaration(annotations=[], declarators=[VariableDeclarator(... | Keyword[public] Keyword[static] identifier[Map] operator[<] identifier[String] , identifier[Set] operator[<] identifier[InetAddress] operator[>] operator[>] identifier[getNetworkInterfaceAddresses] operator[SEP] Keyword[boolean] identifier[includeLoopback] operator[SEP] {
identifier[Map] operator[<] identifier[... |
public static Object[] convertParameters(Object[] parms) {
if (parms == null)
return null;
if (parms.length == 0)
return parms;
// create a new array to hold the output
Object[] newParms = new Object[parms.length];
// convert empty strings to ""
... | class class_name[name] begin[{]
method[convertParameters, return_type[type[Object]], modifier[public static], parameter[parms]] begin[{]
if[binary_operation[member[.parms], ==, literal[null]]] begin[{]
return[literal[null]]
else begin[{]
None
end[}]
if[binary_ope... | Keyword[public] Keyword[static] identifier[Object] operator[SEP] operator[SEP] identifier[convertParameters] operator[SEP] identifier[Object] operator[SEP] operator[SEP] identifier[parms] operator[SEP] {
Keyword[if] operator[SEP] identifier[parms] operator[==] Other[null] operator[SEP] Keyword[return] Other[null... |
private void calculateCL(double[] x) {
if (values != null) {
rvfcalculate(x);
return;
}
//System.out.println("Checking at: "+x[0]+" "+x[1]+" "+x[2]);
value = 0.0;
if (derivative == null) {
derivative = new double[x.length];
} else {
Arrays.fill(derivative, 0.0);... | class class_name[name] begin[{]
method[calculateCL, return_type[void], modifier[private], parameter[x]] begin[{]
if[binary_operation[member[.values], !=, literal[null]]] begin[{]
call[.rvfcalculate, parameter[member[.x]]]
return[None]
else begin[{]
No... | Keyword[private] Keyword[void] identifier[calculateCL] operator[SEP] Keyword[double] operator[SEP] operator[SEP] identifier[x] operator[SEP] {
Keyword[if] operator[SEP] identifier[values] operator[!=] Other[null] operator[SEP] {
identifier[rvfcalculate] operator[SEP] identifier[x] operator[SEP] operat... |
public static SqlRunner create(DataSource ds, String driverClassName) {
return new SqlRunner(ds, DialectFactory.newDialect(driverClassName));
} | class class_name[name] begin[{]
method[create, return_type[type[SqlRunner]], modifier[public static], parameter[ds, driverClassName]] begin[{]
return[ClassCreator(arguments=[MemberReference(member=ds, postfix_operators=[], prefix_operators=[], qualifier=, selectors=[]), MethodInvocation(arguments=[Memb... | Keyword[public] Keyword[static] identifier[SqlRunner] identifier[create] operator[SEP] identifier[DataSource] identifier[ds] , identifier[String] identifier[driverClassName] operator[SEP] {
Keyword[return] Keyword[new] identifier[SqlRunner] operator[SEP] identifier[ds] , identifier[DialectFactory] operator[SEP... |
public boolean overlaps(Location location) {
if (location.getBeginPosition()>=getBeginPosition() && location.getBeginPosition() <= getEndPosition())
return true;
if(location.getBeginPosition() <= getBeginPosition() && location.getEndPosition()>=getBeginPosition())
return tr... | class class_name[name] begin[{]
method[overlaps, return_type[type[boolean]], modifier[public], parameter[location]] begin[{]
if[binary_operation[binary_operation[call[location.getBeginPosition, parameter[]], >=, call[.getBeginPosition, parameter[]]], &&, binary_operation[call[location.getBeginP... | Keyword[public] Keyword[boolean] identifier[overlaps] operator[SEP] identifier[Location] identifier[location] operator[SEP] {
Keyword[if] operator[SEP] identifier[location] operator[SEP] identifier[getBeginPosition] operator[SEP] operator[SEP] operator[>=] identifier[getBeginPosition] operator[SEP] operator[SEP]... |
@Override
public void visit(NodeVisitor v) {
if (v.visit(this)) {
for (AstNode e : getElements()) {
e.visit(v);
}
}
} | class class_name[name] begin[{]
method[visit, return_type[void], modifier[public], parameter[v]] begin[{]
if[call[v.visit, parameter[THIS[]]]] begin[{]
ForStatement(body=BlockStatement(label=None, statements=[StatementExpression(expression=MethodInvocation(arguments=[MemberReference... | annotation[@] identifier[Override] Keyword[public] Keyword[void] identifier[visit] operator[SEP] identifier[NodeVisitor] identifier[v] operator[SEP] {
Keyword[if] operator[SEP] identifier[v] operator[SEP] identifier[visit] operator[SEP] Keyword[this] operator[SEP] operator[SEP] {
Keyword[for] operator... |
public void addConfigurationListener(NodeConfigListener listener) {
StanzaListener conListener = new NodeConfigTranslator(listener);
configEventToListenerMap.put(listener, conListener);
pubSubManager.getConnection().addSyncStanzaListener(conListener, new EventContentFilter(EventElementType.confi... | class class_name[name] begin[{]
method[addConfigurationListener, return_type[void], modifier[public], parameter[listener]] begin[{]
local_variable[type[StanzaListener], conListener]
call[configEventToListenerMap.put, parameter[member[.listener], member[.conListener]]]
ca... | Keyword[public] Keyword[void] identifier[addConfigurationListener] operator[SEP] identifier[NodeConfigListener] identifier[listener] operator[SEP] {
identifier[StanzaListener] identifier[conListener] operator[=] Keyword[new] identifier[NodeConfigTranslator] operator[SEP] identifier[listener] operator[SEP] operat... |
@Override
public DeleteUserPermissionsBoundaryResult deleteUserPermissionsBoundary(DeleteUserPermissionsBoundaryRequest request) {
request = beforeClientExecution(request);
return executeDeleteUserPermissionsBoundary(request);
} | class class_name[name] begin[{]
method[deleteUserPermissionsBoundary, return_type[type[DeleteUserPermissionsBoundaryResult]], modifier[public], parameter[request]] begin[{]
assign[member[.request], call[.beforeClientExecution, parameter[member[.request]]]]
return[call[.executeDeleteUser... | annotation[@] identifier[Override] Keyword[public] identifier[DeleteUserPermissionsBoundaryResult] identifier[deleteUserPermissionsBoundary] operator[SEP] identifier[DeleteUserPermissionsBoundaryRequest] identifier[request] operator[SEP] {
identifier[request] operator[=] identifier[beforeClientExecution] operato... |
protected Map<String, List<MtasParserObject>> createCurrentList() {
Map<String, List<MtasParserObject>> currentList = new HashMap<>();
currentList.put(MAPPING_TYPE_RELATION, new ArrayList<MtasParserObject>());
currentList.put(MAPPING_TYPE_RELATION_ANNOTATION,
new ArrayList<MtasParserObject>());
... | class class_name[name] begin[{]
method[createCurrentList, return_type[type[Map]], modifier[protected], parameter[]] begin[{]
local_variable[type[Map], currentList]
call[currentList.put, parameter[member[.MAPPING_TYPE_RELATION], ClassCreator(arguments=[], body=None, constructor_type_argu... | Keyword[protected] identifier[Map] operator[<] identifier[String] , identifier[List] operator[<] identifier[MtasParserObject] operator[>] operator[>] identifier[createCurrentList] operator[SEP] operator[SEP] {
identifier[Map] operator[<] identifier[String] , identifier[List] operator[<] identifier[MtasParserOb... |
public static dnsaddrec[] get_filtered(nitro_service service, String filter) throws Exception{
dnsaddrec obj = new dnsaddrec();
options option = new options();
option.set_filter(filter);
dnsaddrec[] response = (dnsaddrec[]) obj.getfiltered(service, option);
return response;
} | class class_name[name] begin[{]
method[get_filtered, return_type[type[dnsaddrec]], modifier[public static], parameter[service, filter]] begin[{]
local_variable[type[dnsaddrec], obj]
local_variable[type[options], option]
call[option.set_filter, parameter[member[.filter]]]
... | Keyword[public] Keyword[static] identifier[dnsaddrec] operator[SEP] operator[SEP] identifier[get_filtered] operator[SEP] identifier[nitro_service] identifier[service] , identifier[String] identifier[filter] operator[SEP] Keyword[throws] identifier[Exception] {
identifier[dnsaddrec] identifier[obj] operator[=] K... |
public static final int compare(final Object obj0, final Object obj1)
throws ELException {
return compare(null, obj0, obj1);
} | class class_name[name] begin[{]
method[compare, return_type[type[int]], modifier[final public static], parameter[obj0, obj1]] begin[{]
return[call[.compare, parameter[literal[null], member[.obj0], member[.obj1]]]]
end[}]
END[}] | Keyword[public] Keyword[static] Keyword[final] Keyword[int] identifier[compare] operator[SEP] Keyword[final] identifier[Object] identifier[obj0] , Keyword[final] identifier[Object] identifier[obj1] operator[SEP] Keyword[throws] identifier[ELException] {
Keyword[return] identifier[compare] operator[SEP] Other[nu... |
public SequenceView<C> get(int index) {
int start = toStartIndex(index);
int end = index + (getWindowSize() - 1);
return getBackingSequence().getSubSequence(start, end);
} | class class_name[name] begin[{]
method[get, return_type[type[SequenceView]], modifier[public], parameter[index]] begin[{]
local_variable[type[int], start]
local_variable[type[int], end]
return[call[.getBackingSequence, parameter[]]]
end[}]
END[}] | Keyword[public] identifier[SequenceView] operator[<] identifier[C] operator[>] identifier[get] operator[SEP] Keyword[int] identifier[index] operator[SEP] {
Keyword[int] identifier[start] operator[=] identifier[toStartIndex] operator[SEP] identifier[index] operator[SEP] operator[SEP] Keyword[int] identifier[end] ... |
private String getPath(URL url) {
String path = url.toExternalForm();
return path.replaceAll("bundle://[^/]*/", "");
} | class class_name[name] begin[{]
method[getPath, return_type[type[String]], modifier[private], parameter[url]] begin[{]
local_variable[type[String], path]
return[call[path.replaceAll, parameter[literal["bundle://[^/]*/"], literal[""]]]]
end[}]
END[}] | Keyword[private] identifier[String] identifier[getPath] operator[SEP] identifier[URL] identifier[url] operator[SEP] {
identifier[String] identifier[path] operator[=] identifier[url] operator[SEP] identifier[toExternalForm] operator[SEP] operator[SEP] operator[SEP] Keyword[return] identifier[path] operator[SEP] i... |
@Override
protected void populateModel(ModelNode operation, ModelNode model) throws OperationFailedException {
model.get(ModelConstants.PROCESS_ENGINES);
} | class class_name[name] begin[{]
method[populateModel, return_type[void], modifier[protected], parameter[operation, model]] begin[{]
call[model.get, parameter[member[ModelConstants.PROCESS_ENGINES]]]
end[}]
END[}] | annotation[@] identifier[Override] Keyword[protected] Keyword[void] identifier[populateModel] operator[SEP] identifier[ModelNode] identifier[operation] , identifier[ModelNode] identifier[model] operator[SEP] Keyword[throws] identifier[OperationFailedException] {
identifier[model] operator[SEP] identifier[get] o... |
private static Image uploadImage(
AdWordsServicesInterface services, AdWordsSession session, String url) throws IOException {
Image image = new Image();
image.setType(MediaMediaType.IMAGE);
image.setData(com.google.api.ads.common.lib.utils.Media.getMediaDataFromUrl(url));
MediaServiceInterface med... | class class_name[name] begin[{]
method[uploadImage, return_type[type[Image]], modifier[private static], parameter[services, session, url]] begin[{]
local_variable[type[Image], image]
call[image.setType, parameter[member[MediaMediaType.IMAGE]]]
call[image.setData, paramet... | Keyword[private] Keyword[static] identifier[Image] identifier[uploadImage] operator[SEP] identifier[AdWordsServicesInterface] identifier[services] , identifier[AdWordsSession] identifier[session] , identifier[String] identifier[url] operator[SEP] Keyword[throws] identifier[IOException] {
identifier[Image] iden... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.