id int32 0 165k | repo stringlengths 7 58 | path stringlengths 12 218 | func_name stringlengths 3 140 | original_string stringlengths 73 34.1k | language stringclasses 1
value | code stringlengths 73 34.1k | code_tokens list | docstring stringlengths 3 16k | docstring_tokens list | sha stringlengths 40 40 | url stringlengths 105 339 |
|---|---|---|---|---|---|---|---|---|---|---|---|
56,400 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/grid/Pager.java | Pager.setRecordsAmount | public void setRecordsAmount(int amount) {
int ipp = Integer.parseInt(itemsPerPageEditor.getValueAsString());
pageTotal = amount % ipp == 0? amount / ipp : amount / ipp + 1;
draw(0);
} | java | public void setRecordsAmount(int amount) {
int ipp = Integer.parseInt(itemsPerPageEditor.getValueAsString());
pageTotal = amount % ipp == 0? amount / ipp : amount / ipp + 1;
draw(0);
} | [
"public",
"void",
"setRecordsAmount",
"(",
"int",
"amount",
")",
"{",
"int",
"ipp",
"=",
"Integer",
".",
"parseInt",
"(",
"itemsPerPageEditor",
".",
"getValueAsString",
"(",
")",
")",
";",
"pageTotal",
"=",
"amount",
"%",
"ipp",
"==",
"0",
"?",
"amount",
... | Assigns total number of records.
@param amount | [
"Assigns",
"total",
"number",
"of",
"records",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/grid/Pager.java#L90-L94 |
56,401 | ModeShape/modeshape | sequencers/modeshape-sequencer-ddl/src/main/java/org/modeshape/sequencer/ddl/DdlParsers.java | DdlParsers.parseUsing | public List<ParsingResult> parseUsing( final String ddl,
final String firstParserId,
final String secondParserId,
final String... additionalParserIds ) throws ParsingException {
Check... | java | public List<ParsingResult> parseUsing( final String ddl,
final String firstParserId,
final String secondParserId,
final String... additionalParserIds ) throws ParsingException {
Check... | [
"public",
"List",
"<",
"ParsingResult",
">",
"parseUsing",
"(",
"final",
"String",
"ddl",
",",
"final",
"String",
"firstParserId",
",",
"final",
"String",
"secondParserId",
",",
"final",
"String",
"...",
"additionalParserIds",
")",
"throws",
"ParsingException",
"{... | Parse the supplied DDL using multiple parsers, returning the result of each parser with its score in the order of highest
scoring to lowest scoring.
@param ddl the DDL being parsed (cannot be <code>null</code> or empty)
@param firstParserId the identifier of the first parser to use (cannot be <code>null</code> or empt... | [
"Parse",
"the",
"supplied",
"DDL",
"using",
"multiple",
"parsers",
"returning",
"the",
"result",
"of",
"each",
"parser",
"with",
"its",
"score",
"in",
"the",
"order",
"of",
"highest",
"scoring",
"to",
"lowest",
"scoring",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/sequencers/modeshape-sequencer-ddl/src/main/java/org/modeshape/sequencer/ddl/DdlParsers.java#L183-L231 |
56,402 | ModeShape/modeshape | web/modeshape-web-jcr-webdav/src/main/java/org/modeshape/web/jcr/webdav/ResolvedRequest.java | ResolvedRequest.withPath | public ResolvedRequest withPath( String path ) {
assert repositoryName != null;
assert workspaceName != null;
return new ResolvedRequest(request, repositoryName, workspaceName, path);
} | java | public ResolvedRequest withPath( String path ) {
assert repositoryName != null;
assert workspaceName != null;
return new ResolvedRequest(request, repositoryName, workspaceName, path);
} | [
"public",
"ResolvedRequest",
"withPath",
"(",
"String",
"path",
")",
"{",
"assert",
"repositoryName",
"!=",
"null",
";",
"assert",
"workspaceName",
"!=",
"null",
";",
"return",
"new",
"ResolvedRequest",
"(",
"request",
",",
"repositoryName",
",",
"workspaceName",
... | Create a new request that is similar to this request except with the supplied path. This can only be done if the repository
name and workspace name are non-null
@param path the new path
@return the new request; never null | [
"Create",
"a",
"new",
"request",
"that",
"is",
"similar",
"to",
"this",
"request",
"except",
"with",
"the",
"supplied",
"path",
".",
"This",
"can",
"only",
"be",
"done",
"if",
"the",
"repository",
"name",
"and",
"workspace",
"name",
"are",
"non",
"-",
"n... | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-jcr-webdav/src/main/java/org/modeshape/web/jcr/webdav/ResolvedRequest.java#L84-L88 |
56,403 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.findJcrName | public String findJcrName( String cmisName ) {
for (int i = 0; i < list.size(); i++) {
if (list.get(i).cmisName != null && list.get(i).cmisName.equals(cmisName)) {
return list.get(i).jcrName;
}
}
return cmisName;
} | java | public String findJcrName( String cmisName ) {
for (int i = 0; i < list.size(); i++) {
if (list.get(i).cmisName != null && list.get(i).cmisName.equals(cmisName)) {
return list.get(i).jcrName;
}
}
return cmisName;
} | [
"public",
"String",
"findJcrName",
"(",
"String",
"cmisName",
")",
"{",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"list",
".",
"size",
"(",
")",
";",
"i",
"++",
")",
"{",
"if",
"(",
"list",
".",
"get",
"(",
"i",
")",
".",
"cmisName",
"... | Determines the name of the given property from cmis domain in jcr domain.
@param cmisName the name of property in cmis domain.
@return the name of the same property in jcr domain. | [
"Determines",
"the",
"name",
"of",
"the",
"given",
"property",
"from",
"cmis",
"domain",
"in",
"jcr",
"domain",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L82-L89 |
56,404 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.findCmisName | public String findCmisName( String jcrName ) {
for (int i = 0; i < list.size(); i++) {
if (list.get(i).jcrName != null && list.get(i).jcrName.equals(jcrName)) {
return list.get(i).cmisName;
}
}
return jcrName;
} | java | public String findCmisName( String jcrName ) {
for (int i = 0; i < list.size(); i++) {
if (list.get(i).jcrName != null && list.get(i).jcrName.equals(jcrName)) {
return list.get(i).cmisName;
}
}
return jcrName;
} | [
"public",
"String",
"findCmisName",
"(",
"String",
"jcrName",
")",
"{",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"list",
".",
"size",
"(",
")",
";",
"i",
"++",
")",
"{",
"if",
"(",
"list",
".",
"get",
"(",
"i",
")",
".",
"jcrName",
"!... | Determines the name of the given property from jcr domain in cmis domain.
@param jcrName the name of property in jcr domain.
@return the name of the same property in cmis domain. | [
"Determines",
"the",
"name",
"of",
"the",
"given",
"property",
"from",
"jcr",
"domain",
"in",
"cmis",
"domain",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L97-L104 |
56,405 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.getJcrType | public int getJcrType( PropertyType propertyType ) {
switch (propertyType) {
case BOOLEAN:
return javax.jcr.PropertyType.BOOLEAN;
case DATETIME:
return javax.jcr.PropertyType.DATE;
case DECIMAL:
return javax.jcr.PropertyType.DEC... | java | public int getJcrType( PropertyType propertyType ) {
switch (propertyType) {
case BOOLEAN:
return javax.jcr.PropertyType.BOOLEAN;
case DATETIME:
return javax.jcr.PropertyType.DATE;
case DECIMAL:
return javax.jcr.PropertyType.DEC... | [
"public",
"int",
"getJcrType",
"(",
"PropertyType",
"propertyType",
")",
"{",
"switch",
"(",
"propertyType",
")",
"{",
"case",
"BOOLEAN",
":",
"return",
"javax",
".",
"jcr",
".",
"PropertyType",
".",
"BOOLEAN",
";",
"case",
"DATETIME",
":",
"return",
"javax"... | Converts type of property.
@param propertyType the type of the property in cmis domain.
@return the type of the property in jcr domain. | [
"Converts",
"type",
"of",
"property",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L112-L131 |
56,406 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.jcrValues | public Object[] jcrValues( Property<?> property ) {
@SuppressWarnings( "unchecked" )
List<Object> values = (List<Object>)property.getValues();
// convert CMIS values to JCR values
switch (property.getType()) {
case STRING:
return asStrings(values);
... | java | public Object[] jcrValues( Property<?> property ) {
@SuppressWarnings( "unchecked" )
List<Object> values = (List<Object>)property.getValues();
// convert CMIS values to JCR values
switch (property.getType()) {
case STRING:
return asStrings(values);
... | [
"public",
"Object",
"[",
"]",
"jcrValues",
"(",
"Property",
"<",
"?",
">",
"property",
")",
"{",
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"List",
"<",
"Object",
">",
"values",
"=",
"(",
"List",
"<",
"Object",
">",
")",
"property",
".",
"getV... | Converts value of the property for the jcr domain.
@param property property in cmis domain
@return value of the given property in jcr domain. | [
"Converts",
"value",
"of",
"the",
"property",
"for",
"the",
"jcr",
"domain",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L213-L238 |
56,407 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.asBooleans | private Boolean[] asBooleans( List<Object> values ) {
ValueFactory<Boolean> factory = valueFactories.getBooleanFactory();
Boolean[] res = new Boolean[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return res;
} | java | private Boolean[] asBooleans( List<Object> values ) {
ValueFactory<Boolean> factory = valueFactories.getBooleanFactory();
Boolean[] res = new Boolean[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return res;
} | [
"private",
"Boolean",
"[",
"]",
"asBooleans",
"(",
"List",
"<",
"Object",
">",
"values",
")",
"{",
"ValueFactory",
"<",
"Boolean",
">",
"factory",
"=",
"valueFactories",
".",
"getBooleanFactory",
"(",
")",
";",
"Boolean",
"[",
"]",
"res",
"=",
"new",
"Bo... | Converts CMIS value of boolean type into JCR value of boolean type.
@param values CMIS values of boolean type
@return JCR values of boolean type | [
"Converts",
"CMIS",
"value",
"of",
"boolean",
"type",
"into",
"JCR",
"value",
"of",
"boolean",
"type",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L246-L253 |
56,408 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.asIntegers | private Long[] asIntegers( List<Object> values ) {
ValueFactory<Long> factory = valueFactories.getLongFactory();
Long[] res = new Long[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return res;
} | java | private Long[] asIntegers( List<Object> values ) {
ValueFactory<Long> factory = valueFactories.getLongFactory();
Long[] res = new Long[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return res;
} | [
"private",
"Long",
"[",
"]",
"asIntegers",
"(",
"List",
"<",
"Object",
">",
"values",
")",
"{",
"ValueFactory",
"<",
"Long",
">",
"factory",
"=",
"valueFactories",
".",
"getLongFactory",
"(",
")",
";",
"Long",
"[",
"]",
"res",
"=",
"new",
"Long",
"[",
... | Converts CMIS value of integer type into JCR value of boolean type.
@param values CMIS values of integer type
@return JCR values of integer type | [
"Converts",
"CMIS",
"value",
"of",
"integer",
"type",
"into",
"JCR",
"value",
"of",
"boolean",
"type",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L276-L283 |
56,409 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.asDecimals | private BigDecimal[] asDecimals( List<Object> values ) {
ValueFactory<BigDecimal> factory = valueFactories.getDecimalFactory();
BigDecimal[] res = new BigDecimal[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return re... | java | private BigDecimal[] asDecimals( List<Object> values ) {
ValueFactory<BigDecimal> factory = valueFactories.getDecimalFactory();
BigDecimal[] res = new BigDecimal[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return re... | [
"private",
"BigDecimal",
"[",
"]",
"asDecimals",
"(",
"List",
"<",
"Object",
">",
"values",
")",
"{",
"ValueFactory",
"<",
"BigDecimal",
">",
"factory",
"=",
"valueFactories",
".",
"getDecimalFactory",
"(",
")",
";",
"BigDecimal",
"[",
"]",
"res",
"=",
"ne... | Converts CMIS value of decimal type into JCR value of boolean type.
@param values CMIS values of decimal type
@return JCR values of decimal type | [
"Converts",
"CMIS",
"value",
"of",
"decimal",
"type",
"into",
"JCR",
"value",
"of",
"boolean",
"type",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L291-L298 |
56,410 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.asURI | private URI[] asURI( List<Object> values ) {
ValueFactory<URI> factory = valueFactories.getUriFactory();
URI[] res = new URI[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(((GregorianCalendar)values.get(i)).getTime());
}
return res;
... | java | private URI[] asURI( List<Object> values ) {
ValueFactory<URI> factory = valueFactories.getUriFactory();
URI[] res = new URI[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(((GregorianCalendar)values.get(i)).getTime());
}
return res;
... | [
"private",
"URI",
"[",
"]",
"asURI",
"(",
"List",
"<",
"Object",
">",
"values",
")",
"{",
"ValueFactory",
"<",
"URI",
">",
"factory",
"=",
"valueFactories",
".",
"getUriFactory",
"(",
")",
";",
"URI",
"[",
"]",
"res",
"=",
"new",
"URI",
"[",
"values"... | Converts CMIS value of URI type into JCR value of URI type.
@param values CMIS values of URI type
@return JCR values of URI type | [
"Converts",
"CMIS",
"value",
"of",
"URI",
"type",
"into",
"JCR",
"value",
"of",
"URI",
"type",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L321-L328 |
56,411 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java | Properties.asIDs | private String[] asIDs( List<Object> values ) {
ValueFactory<String> factory = valueFactories.getStringFactory();
String[] res = new String[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return res;
} | java | private String[] asIDs( List<Object> values ) {
ValueFactory<String> factory = valueFactories.getStringFactory();
String[] res = new String[values.size()];
for (int i = 0; i < res.length; i++) {
res[i] = factory.create(values.get(i));
}
return res;
} | [
"private",
"String",
"[",
"]",
"asIDs",
"(",
"List",
"<",
"Object",
">",
"values",
")",
"{",
"ValueFactory",
"<",
"String",
">",
"factory",
"=",
"valueFactories",
".",
"getStringFactory",
"(",
")",
";",
"String",
"[",
"]",
"res",
"=",
"new",
"String",
... | Converts CMIS value of ID type into JCR value of String type.
@param values CMIS values of Id type
@return JCR values of String type | [
"Converts",
"CMIS",
"value",
"of",
"ID",
"type",
"into",
"JCR",
"value",
"of",
"String",
"type",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/Properties.java#L336-L343 |
56,412 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/Sequencers.java | Sequencers.workspaceAdded | protected void workspaceAdded( String workspaceName ) {
String workspaceKey = NodeKey.keyForWorkspaceName(workspaceName);
if (systemWorkspaceKey.equals(workspaceKey)) {
// No sequencers for the system workspace!
return;
}
Collection<SequencingConfiguration> config... | java | protected void workspaceAdded( String workspaceName ) {
String workspaceKey = NodeKey.keyForWorkspaceName(workspaceName);
if (systemWorkspaceKey.equals(workspaceKey)) {
// No sequencers for the system workspace!
return;
}
Collection<SequencingConfiguration> config... | [
"protected",
"void",
"workspaceAdded",
"(",
"String",
"workspaceName",
")",
"{",
"String",
"workspaceKey",
"=",
"NodeKey",
".",
"keyForWorkspaceName",
"(",
"workspaceName",
")",
";",
"if",
"(",
"systemWorkspaceKey",
".",
"equals",
"(",
"workspaceKey",
")",
")",
... | Signal that a new workspace was added.
@param workspaceName the workspace name; may not be null | [
"Signal",
"that",
"a",
"new",
"workspace",
"was",
"added",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/Sequencers.java#L272-L307 |
56,413 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/Sequencers.java | Sequencers.workspaceRemoved | protected void workspaceRemoved( String workspaceName ) {
// Otherwise, update the configs by workspace key ...
try {
configChangeLock.lock();
// Make a copy of the existing map ...
Map<String, Collection<SequencingConfiguration>> configByWorkspaceName = new HashMap<S... | java | protected void workspaceRemoved( String workspaceName ) {
// Otherwise, update the configs by workspace key ...
try {
configChangeLock.lock();
// Make a copy of the existing map ...
Map<String, Collection<SequencingConfiguration>> configByWorkspaceName = new HashMap<S... | [
"protected",
"void",
"workspaceRemoved",
"(",
"String",
"workspaceName",
")",
"{",
"// Otherwise, update the configs by workspace key ...",
"try",
"{",
"configChangeLock",
".",
"lock",
"(",
")",
";",
"// Make a copy of the existing map ...",
"Map",
"<",
"String",
",",
"Co... | Signal that a new workspace was removed.
@param workspaceName the workspace name; may not be null | [
"Signal",
"that",
"a",
"new",
"workspace",
"was",
"removed",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/Sequencers.java#L314-L329 |
56,414 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/naming/SingletonInitialContext.java | SingletonInitialContext.register | public static void register( String name,
Object obj ) {
register(name, obj, null, null, null, null);
} | java | public static void register( String name,
Object obj ) {
register(name, obj, null, null, null, null);
} | [
"public",
"static",
"void",
"register",
"(",
"String",
"name",
",",
"Object",
"obj",
")",
"{",
"register",
"(",
"name",
",",
"obj",
",",
"null",
",",
"null",
",",
"null",
",",
"null",
")",
";",
"}"
] | A convenience method that registers the supplied object with the supplied name.
@param name the JNDI name
@param obj the object to be registered | [
"A",
"convenience",
"method",
"that",
"registers",
"the",
"supplied",
"object",
"with",
"the",
"supplied",
"name",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/naming/SingletonInitialContext.java#L68-L71 |
56,415 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/cache/change/AbstractNodeChange.java | AbstractNodeChange.getMixinTypes | public Set<Name> getMixinTypes() {
if (types.length == 1) {
return Collections.emptySet();
}
return new HashSet<Name>(Arrays.asList(Arrays.copyOfRange(types, 1, types.length)));
} | java | public Set<Name> getMixinTypes() {
if (types.length == 1) {
return Collections.emptySet();
}
return new HashSet<Name>(Arrays.asList(Arrays.copyOfRange(types, 1, types.length)));
} | [
"public",
"Set",
"<",
"Name",
">",
"getMixinTypes",
"(",
")",
"{",
"if",
"(",
"types",
".",
"length",
"==",
"1",
")",
"{",
"return",
"Collections",
".",
"emptySet",
"(",
")",
";",
"}",
"return",
"new",
"HashSet",
"<",
"Name",
">",
"(",
"Arrays",
".... | Returns the mixins for this node.
@return a {@link Set}; never {@code null} but possibly empty. | [
"Returns",
"the",
"mixins",
"for",
"this",
"node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/cache/change/AbstractNodeChange.java#L91-L96 |
56,416 | ModeShape/modeshape | sequencers/modeshape-sequencer-java/src/main/java/org/modeshape/sequencer/javafile/metadata/AbstractMetadata.java | AbstractMetadata.hasModifierNamed | private boolean hasModifierNamed( String modifierName ) {
for (ModifierMetadata modifier : modifiers) {
if (modifierName.equalsIgnoreCase(modifier.getName())) {
return true;
}
}
return false;
} | java | private boolean hasModifierNamed( String modifierName ) {
for (ModifierMetadata modifier : modifiers) {
if (modifierName.equalsIgnoreCase(modifier.getName())) {
return true;
}
}
return false;
} | [
"private",
"boolean",
"hasModifierNamed",
"(",
"String",
"modifierName",
")",
"{",
"for",
"(",
"ModifierMetadata",
"modifier",
":",
"modifiers",
")",
"{",
"if",
"(",
"modifierName",
".",
"equalsIgnoreCase",
"(",
"modifier",
".",
"getName",
"(",
")",
")",
")",
... | Checks if a modifier with the given name is found among this method's identifiers.
@param modifierName the name of the modifier to check for
@return true if the type has a modifier of that name, otherwise false | [
"Checks",
"if",
"a",
"modifier",
"with",
"the",
"given",
"name",
"is",
"found",
"among",
"this",
"method",
"s",
"identifiers",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/sequencers/modeshape-sequencer-java/src/main/java/org/modeshape/sequencer/javafile/metadata/AbstractMetadata.java#L113-L122 |
56,417 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/statistic/DetailedStatistics.java | DetailedStatistics.getMedianValue | public double getMedianValue() {
Lock lock = this.getLock().writeLock();
try {
lock.lock();
int count = this.values.size();
if (count == 0) {
return 0.0d;
}
if (this.medianValue == null) {
// Sort the values in n... | java | public double getMedianValue() {
Lock lock = this.getLock().writeLock();
try {
lock.lock();
int count = this.values.size();
if (count == 0) {
return 0.0d;
}
if (this.medianValue == null) {
// Sort the values in n... | [
"public",
"double",
"getMedianValue",
"(",
")",
"{",
"Lock",
"lock",
"=",
"this",
".",
"getLock",
"(",
")",
".",
"writeLock",
"(",
")",
";",
"try",
"{",
"lock",
".",
"lock",
"(",
")",
";",
"int",
"count",
"=",
"this",
".",
"values",
".",
"size",
... | Return the median value.
@return the median value, or 0.0 if the {@link #getCount() count} is 0
@see #getMedian() | [
"Return",
"the",
"median",
"value",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/statistic/DetailedStatistics.java#L129-L165 |
56,418 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/statistic/DetailedStatistics.java | DetailedStatistics.getStandardDeviation | public double getStandardDeviation() {
Lock lock = this.getLock().readLock();
lock.lock();
try {
return this.sigma;
} finally {
lock.unlock();
}
} | java | public double getStandardDeviation() {
Lock lock = this.getLock().readLock();
lock.lock();
try {
return this.sigma;
} finally {
lock.unlock();
}
} | [
"public",
"double",
"getStandardDeviation",
"(",
")",
"{",
"Lock",
"lock",
"=",
"this",
".",
"getLock",
"(",
")",
".",
"readLock",
"(",
")",
";",
"lock",
".",
"lock",
"(",
")",
";",
"try",
"{",
"return",
"this",
".",
"sigma",
";",
"}",
"finally",
"... | Return the standard deviation. The standard deviation is a measure of the variation in a series of values. Values with a
lower standard deviation has less variance in the values than a series of values with a higher standard deviation.
@return the standard deviation, or 0.0 if the {@link #getCount() count} is 0 or if a... | [
"Return",
"the",
"standard",
"deviation",
".",
"The",
"standard",
"deviation",
"is",
"a",
"measure",
"of",
"the",
"variation",
"in",
"a",
"series",
"of",
"values",
".",
"Values",
"with",
"a",
"lower",
"standard",
"deviation",
"has",
"less",
"variance",
"in",... | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/statistic/DetailedStatistics.java#L172-L180 |
56,419 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/BackupService.java | BackupService.backupRepository | public org.modeshape.jcr.api.Problems backupRepository( File backupDirectory, BackupOptions options ) throws RepositoryException {
// Create the activity ...
final BackupActivity backupActivity = createBackupActivity(backupDirectory, options);
//suspend any existing transactions
try {
... | java | public org.modeshape.jcr.api.Problems backupRepository( File backupDirectory, BackupOptions options ) throws RepositoryException {
// Create the activity ...
final BackupActivity backupActivity = createBackupActivity(backupDirectory, options);
//suspend any existing transactions
try {
... | [
"public",
"org",
".",
"modeshape",
".",
"jcr",
".",
"api",
".",
"Problems",
"backupRepository",
"(",
"File",
"backupDirectory",
",",
"BackupOptions",
"options",
")",
"throws",
"RepositoryException",
"{",
"// Create the activity ...",
"final",
"BackupActivity",
"backup... | Start backing up the repository.
@param backupDirectory the directory on the file system into which the backup should be placed; this directory should
typically not exist
@param options a {@link org.modeshape.jcr.api.BackupOptions} instance controlling the behavior of the backup; may not be
{@code null}
@return the pr... | [
"Start",
"backing",
"up",
"the",
"repository",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/BackupService.java#L118-L136 |
56,420 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/BackupService.java | BackupService.restoreRepository | public org.modeshape.jcr.api.Problems restoreRepository( final JcrRepository repository,
final File backupDirectory,
final RestoreOptions options) throws RepositoryException {
final String b... | java | public org.modeshape.jcr.api.Problems restoreRepository( final JcrRepository repository,
final File backupDirectory,
final RestoreOptions options) throws RepositoryException {
final String b... | [
"public",
"org",
".",
"modeshape",
".",
"jcr",
".",
"api",
".",
"Problems",
"restoreRepository",
"(",
"final",
"JcrRepository",
"repository",
",",
"final",
"File",
"backupDirectory",
",",
"final",
"RestoreOptions",
"options",
")",
"throws",
"RepositoryException",
... | Start asynchronously backing up the repository.
@param repository the JCR repository to be backed up; may not be null
@param backupDirectory the directory on the file system that contains the backup; this directory obviously must exist
@param options a {@link org.modeshape.jcr.api.RestoreOptions} instance which contro... | [
"Start",
"asynchronously",
"backing",
"up",
"the",
"repository",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/BackupService.java#L147-L182 |
56,421 | ModeShape/modeshape | extractors/modeshape-extractor-tika/src/main/java/org/modeshape/extractor/tika/TikaTextExtractor.java | TikaTextExtractor.prepareMetadata | protected final Metadata prepareMetadata( final Binary binary,
final Context context ) throws IOException, RepositoryException {
Metadata metadata = new Metadata();
String mimeType = binary.getMimeType();
if (StringUtil.isBlank(mimeType)) {
... | java | protected final Metadata prepareMetadata( final Binary binary,
final Context context ) throws IOException, RepositoryException {
Metadata metadata = new Metadata();
String mimeType = binary.getMimeType();
if (StringUtil.isBlank(mimeType)) {
... | [
"protected",
"final",
"Metadata",
"prepareMetadata",
"(",
"final",
"Binary",
"binary",
",",
"final",
"Context",
"context",
")",
"throws",
"IOException",
",",
"RepositoryException",
"{",
"Metadata",
"metadata",
"=",
"new",
"Metadata",
"(",
")",
";",
"String",
"mi... | Creates a new tika metadata object used by the parser. This will contain the mime-type of the content being parsed, if this
is available to the underlying context. If not, Tika's autodetection mechanism is used to try and get the mime-type.
@param binary a <code>org.modeshape.jcr.api.Binary</code> instance of the cont... | [
"Creates",
"a",
"new",
"tika",
"metadata",
"object",
"used",
"by",
"the",
"parser",
".",
"This",
"will",
"contain",
"the",
"mime",
"-",
"type",
"of",
"the",
"content",
"being",
"parsed",
"if",
"this",
"is",
"available",
"to",
"the",
"underlying",
"context"... | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/extractors/modeshape-extractor-tika/src/main/java/org/modeshape/extractor/tika/TikaTextExtractor.java#L170-L183 |
56,422 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java | MongodbBinaryStore.convertToServerAddresses | private List<ServerAddress> convertToServerAddresses(Set<String> addresses) {
return addresses.stream()
.map(this::stringToServerAddress)
.filter(Objects::nonNull)
.collect(Collectors.toList());
} | java | private List<ServerAddress> convertToServerAddresses(Set<String> addresses) {
return addresses.stream()
.map(this::stringToServerAddress)
.filter(Objects::nonNull)
.collect(Collectors.toList());
} | [
"private",
"List",
"<",
"ServerAddress",
">",
"convertToServerAddresses",
"(",
"Set",
"<",
"String",
">",
"addresses",
")",
"{",
"return",
"addresses",
".",
"stream",
"(",
")",
".",
"map",
"(",
"this",
"::",
"stringToServerAddress",
")",
".",
"filter",
"(",
... | Converts list of addresses specified in text format to mongodb specific address.
@param addresses list of addresses in text format
@return list of mongodb addresses
@throws IllegalArgumentException if address has bad format or is not valid | [
"Converts",
"list",
"of",
"addresses",
"specified",
"in",
"text",
"format",
"to",
"mongodb",
"specific",
"address",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java#L132-L137 |
56,423 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java | MongodbBinaryStore.setAttribute | private void setAttribute( DBCollection content,
String fieldName,
Object value ) {
DBObject header = content.findOne(HEADER_QUERY);
BasicDBObject newHeader = new BasicDBObject();
// clone header
newHeader.put(FIELD_CHUNK_TYP... | java | private void setAttribute( DBCollection content,
String fieldName,
Object value ) {
DBObject header = content.findOne(HEADER_QUERY);
BasicDBObject newHeader = new BasicDBObject();
// clone header
newHeader.put(FIELD_CHUNK_TYP... | [
"private",
"void",
"setAttribute",
"(",
"DBCollection",
"content",
",",
"String",
"fieldName",
",",
"Object",
"value",
")",
"{",
"DBObject",
"header",
"=",
"content",
".",
"findOne",
"(",
"HEADER_QUERY",
")",
";",
"BasicDBObject",
"newHeader",
"=",
"new",
"Bas... | Modifies content header.
@param content stored content
@param fieldName attribute name
@param value new value for the attribute | [
"Modifies",
"content",
"header",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java#L361-L377 |
56,424 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java | MongodbBinaryStore.getAttribute | private Object getAttribute( DBCollection content,
String fieldName ) {
return content.findOne(HEADER_QUERY).get(fieldName);
} | java | private Object getAttribute( DBCollection content,
String fieldName ) {
return content.findOne(HEADER_QUERY).get(fieldName);
} | [
"private",
"Object",
"getAttribute",
"(",
"DBCollection",
"content",
",",
"String",
"fieldName",
")",
"{",
"return",
"content",
".",
"findOne",
"(",
"HEADER_QUERY",
")",
".",
"get",
"(",
"fieldName",
")",
";",
"}"
] | Gets attribute's value.
@param content stored content
@param fieldName attribute name
@return attributes value | [
"Gets",
"attribute",
"s",
"value",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java#L386-L389 |
56,425 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java | MongodbBinaryStore.isExpired | private boolean isExpired( DBCollection content,
long deadline ) {
Long unusedSince = (Long)getAttribute(content, FIELD_UNUSED_SINCE);
return unusedSince != null && unusedSince < deadline;
} | java | private boolean isExpired( DBCollection content,
long deadline ) {
Long unusedSince = (Long)getAttribute(content, FIELD_UNUSED_SINCE);
return unusedSince != null && unusedSince < deadline;
} | [
"private",
"boolean",
"isExpired",
"(",
"DBCollection",
"content",
",",
"long",
"deadline",
")",
"{",
"Long",
"unusedSince",
"=",
"(",
"Long",
")",
"getAttribute",
"(",
"content",
",",
"FIELD_UNUSED_SINCE",
")",
";",
"return",
"unusedSince",
"!=",
"null",
"&&"... | Checks status of unused content.
@param content content to check status
@param deadline moment of time in past
@return true if content is marked as unused before the deadline | [
"Checks",
"status",
"of",
"unused",
"content",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/value/binary/MongodbBinaryStore.java#L398-L402 |
56,426 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/optimize/PushSelectCriteria.java | PushSelectCriteria.pushDownJoinCriteria | protected boolean pushDownJoinCriteria( PlanNode criteriaNode,
PlanNode joinNode ) {
JoinType joinType = (JoinType)joinNode.getProperty(Property.JOIN_TYPE);
switch (joinType) {
case CROSS:
joinNode.setProperty(Property.JOIN_TYPE, J... | java | protected boolean pushDownJoinCriteria( PlanNode criteriaNode,
PlanNode joinNode ) {
JoinType joinType = (JoinType)joinNode.getProperty(Property.JOIN_TYPE);
switch (joinType) {
case CROSS:
joinNode.setProperty(Property.JOIN_TYPE, J... | [
"protected",
"boolean",
"pushDownJoinCriteria",
"(",
"PlanNode",
"criteriaNode",
",",
"PlanNode",
"joinNode",
")",
"{",
"JoinType",
"joinType",
"=",
"(",
"JoinType",
")",
"joinNode",
".",
"getProperty",
"(",
"Property",
".",
"JOIN_TYPE",
")",
";",
"switch",
"(",... | Attempt to push down criteria that applies to the JOIN as additional constraints on the JOIN itself.
@param criteriaNode the SELECT node; may not be null
@param joinNode the JOIN node; may not be null
@return true if the criteria was pushed down, or false otherwise | [
"Attempt",
"to",
"push",
"down",
"criteria",
"that",
"applies",
"to",
"the",
"JOIN",
"as",
"additional",
"constraints",
"on",
"the",
"JOIN",
"itself",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/optimize/PushSelectCriteria.java#L223-L244 |
56,427 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/optimize/PushSelectCriteria.java | PushSelectCriteria.moveCriteriaIntoOnClause | private void moveCriteriaIntoOnClause( PlanNode criteriaNode,
PlanNode joinNode ) {
List<Constraint> constraints = joinNode.getPropertyAsList(Property.JOIN_CONSTRAINTS, Constraint.class);
Constraint criteria = criteriaNode.getProperty(Property.SELECT_CRITERIA, ... | java | private void moveCriteriaIntoOnClause( PlanNode criteriaNode,
PlanNode joinNode ) {
List<Constraint> constraints = joinNode.getPropertyAsList(Property.JOIN_CONSTRAINTS, Constraint.class);
Constraint criteria = criteriaNode.getProperty(Property.SELECT_CRITERIA, ... | [
"private",
"void",
"moveCriteriaIntoOnClause",
"(",
"PlanNode",
"criteriaNode",
",",
"PlanNode",
"joinNode",
")",
"{",
"List",
"<",
"Constraint",
">",
"constraints",
"=",
"joinNode",
".",
"getPropertyAsList",
"(",
"Property",
".",
"JOIN_CONSTRAINTS",
",",
"Constrain... | Move the criteria that applies to the join to be included in the actual join criteria.
@param criteriaNode the SELECT node; may not be null
@param joinNode the JOIN node; may not be null | [
"Move",
"the",
"criteria",
"that",
"applies",
"to",
"the",
"join",
"to",
"be",
"included",
"in",
"the",
"actual",
"join",
"criteria",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/optimize/PushSelectCriteria.java#L252-L270 |
56,428 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/spi/federation/Connector.java | Connector.moveExtraProperties | protected void moveExtraProperties( String oldNodeId,
String newNodeId ) {
ExtraPropertiesStore extraPropertiesStore = extraPropertiesStore();
if (extraPropertiesStore == null || !extraPropertiesStore.contains(oldNodeId)) {
return;
}
Ma... | java | protected void moveExtraProperties( String oldNodeId,
String newNodeId ) {
ExtraPropertiesStore extraPropertiesStore = extraPropertiesStore();
if (extraPropertiesStore == null || !extraPropertiesStore.contains(oldNodeId)) {
return;
}
Ma... | [
"protected",
"void",
"moveExtraProperties",
"(",
"String",
"oldNodeId",
",",
"String",
"newNodeId",
")",
"{",
"ExtraPropertiesStore",
"extraPropertiesStore",
"=",
"extraPropertiesStore",
"(",
")",
";",
"if",
"(",
"extraPropertiesStore",
"==",
"null",
"||",
"!",
"ext... | Moves a set of extra properties from an old to a new node after their IDs have changed.
@param oldNodeId the old identifier for the node; may not be null
@param newNodeId the new identifier for the node; may not be null | [
"Moves",
"a",
"set",
"of",
"extra",
"properties",
"from",
"an",
"old",
"to",
"a",
"new",
"node",
"after",
"their",
"IDs",
"have",
"changed",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/spi/federation/Connector.java#L298-L307 |
56,429 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/spi/federation/Connector.java | Connector.checkFieldNotNull | protected void checkFieldNotNull( Object fieldValue,
String fieldName ) throws RepositoryException {
if (fieldValue == null) {
throw new RepositoryException(JcrI18n.requiredFieldNotSetInConnector.text(getSourceName(), getClass(), fieldName));
}
} | java | protected void checkFieldNotNull( Object fieldValue,
String fieldName ) throws RepositoryException {
if (fieldValue == null) {
throw new RepositoryException(JcrI18n.requiredFieldNotSetInConnector.text(getSourceName(), getClass(), fieldName));
}
} | [
"protected",
"void",
"checkFieldNotNull",
"(",
"Object",
"fieldValue",
",",
"String",
"fieldName",
")",
"throws",
"RepositoryException",
"{",
"if",
"(",
"fieldValue",
"==",
"null",
")",
"{",
"throw",
"new",
"RepositoryException",
"(",
"JcrI18n",
".",
"requiredFiel... | Utility method that checks whether the field with the supplied name is set.
@param fieldValue the value of the field
@param fieldName the name of the field
@throws RepositoryException if the field value is null | [
"Utility",
"method",
"that",
"checks",
"whether",
"the",
"field",
"with",
"the",
"supplied",
"name",
"is",
"set",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/spi/federation/Connector.java#L515-L520 |
56,430 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/optimize/RuleBasedOptimizer.java | RuleBasedOptimizer.populateRuleStack | protected void populateRuleStack( LinkedList<OptimizerRule> ruleStack,
PlanHints hints ) {
ruleStack.addFirst(ReorderSortAndRemoveDuplicates.INSTANCE);
ruleStack.addFirst(RewritePathAndNameCriteria.INSTANCE);
if (hints.hasSubqueries) {
ruleStack.... | java | protected void populateRuleStack( LinkedList<OptimizerRule> ruleStack,
PlanHints hints ) {
ruleStack.addFirst(ReorderSortAndRemoveDuplicates.INSTANCE);
ruleStack.addFirst(RewritePathAndNameCriteria.INSTANCE);
if (hints.hasSubqueries) {
ruleStack.... | [
"protected",
"void",
"populateRuleStack",
"(",
"LinkedList",
"<",
"OptimizerRule",
">",
"ruleStack",
",",
"PlanHints",
"hints",
")",
"{",
"ruleStack",
".",
"addFirst",
"(",
"ReorderSortAndRemoveDuplicates",
".",
"INSTANCE",
")",
";",
"ruleStack",
".",
"addFirst",
... | Method that is used to create the initial rule stack. This method can be overridden by subclasses
@param ruleStack the stack where the rules should be placed; never null
@param hints the plan hints | [
"Method",
"that",
"is",
"used",
"to",
"create",
"the",
"initial",
"rule",
"stack",
".",
"This",
"method",
"can",
"be",
"overridden",
"by",
"subclasses"
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/optimize/RuleBasedOptimizer.java#L59-L86 |
56,431 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/NodeTypeSchemata.java | NodeTypeSchemata.getSchemataForSession | public Schemata getSchemataForSession( JcrSession session ) {
assert session != null;
// If the session does not override any namespace mappings used in this schemata ...
if (!overridesNamespaceMappings(session)) {
// Then we can just use this schemata instance ...
return... | java | public Schemata getSchemataForSession( JcrSession session ) {
assert session != null;
// If the session does not override any namespace mappings used in this schemata ...
if (!overridesNamespaceMappings(session)) {
// Then we can just use this schemata instance ...
return... | [
"public",
"Schemata",
"getSchemataForSession",
"(",
"JcrSession",
"session",
")",
"{",
"assert",
"session",
"!=",
"null",
";",
"// If the session does not override any namespace mappings used in this schemata ...",
"if",
"(",
"!",
"overridesNamespaceMappings",
"(",
"session",
... | Get a schemata instance that works with the supplied session and that uses the session-specific namespace mappings. Note
that the resulting instance does not change as the session's namespace mappings are changed, so when that happens the
JcrSession must call this method again to obtain a new schemata.
@param session ... | [
"Get",
"a",
"schemata",
"instance",
"that",
"works",
"with",
"the",
"supplied",
"session",
"and",
"that",
"uses",
"the",
"session",
"-",
"specific",
"namespace",
"mappings",
".",
"Note",
"that",
"the",
"resulting",
"instance",
"does",
"not",
"change",
"as",
... | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/NodeTypeSchemata.java#L372-L382 |
56,432 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/NodeTypeSchemata.java | NodeTypeSchemata.overridesNamespaceMappings | private boolean overridesNamespaceMappings( JcrSession session ) {
NamespaceRegistry registry = session.context().getNamespaceRegistry();
if (registry instanceof LocalNamespaceRegistry) {
Set<Namespace> localNamespaces = ((LocalNamespaceRegistry)registry).getLocalNamespaces();
if... | java | private boolean overridesNamespaceMappings( JcrSession session ) {
NamespaceRegistry registry = session.context().getNamespaceRegistry();
if (registry instanceof LocalNamespaceRegistry) {
Set<Namespace> localNamespaces = ((LocalNamespaceRegistry)registry).getLocalNamespaces();
if... | [
"private",
"boolean",
"overridesNamespaceMappings",
"(",
"JcrSession",
"session",
")",
"{",
"NamespaceRegistry",
"registry",
"=",
"session",
".",
"context",
"(",
")",
".",
"getNamespaceRegistry",
"(",
")",
";",
"if",
"(",
"registry",
"instanceof",
"LocalNamespaceReg... | Determine if the session overrides any namespace mappings used by this schemata.
@param session the session; may not be null
@return true if the session overrides one or more namespace mappings used in this schemata, or false otherwise | [
"Determine",
"if",
"the",
"session",
"overrides",
"any",
"namespace",
"mappings",
"used",
"by",
"this",
"schemata",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/NodeTypeSchemata.java#L390-L414 |
56,433 | ModeShape/modeshape | modeshape-schematic/src/main/java/org/modeshape/schematic/internal/document/BasicArray.java | BasicArray.removeValues | private List<Entry> removeValues( Collection<?> values,
boolean ifMatch ) {
LinkedList<Entry> results = null;
// Record the list of entries that are removed, but start at the end of the values (so the indexes are correct)
ListIterator<?> iter = this.values.... | java | private List<Entry> removeValues( Collection<?> values,
boolean ifMatch ) {
LinkedList<Entry> results = null;
// Record the list of entries that are removed, but start at the end of the values (so the indexes are correct)
ListIterator<?> iter = this.values.... | [
"private",
"List",
"<",
"Entry",
">",
"removeValues",
"(",
"Collection",
"<",
"?",
">",
"values",
",",
"boolean",
"ifMatch",
")",
"{",
"LinkedList",
"<",
"Entry",
">",
"results",
"=",
"null",
";",
"// Record the list of entries that are removed, but start at the end... | Remove some of the values in this array.
@param values the values to be compared to this array's values
@param ifMatch true if this method should retain all values that match the supplied values, or false if this method should
remove all values that match the supplied values
@return the entries that were removed; neve... | [
"Remove",
"some",
"of",
"the",
"values",
"in",
"this",
"array",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-schematic/src/main/java/org/modeshape/schematic/internal/document/BasicArray.java#L721-L740 |
56,434 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.isExistCmisObject | private boolean isExistCmisObject(String path) {
try {
session.getObjectByPath(path);
return true;
}
catch (CmisObjectNotFoundException e) {
return false;
}
} | java | private boolean isExistCmisObject(String path) {
try {
session.getObjectByPath(path);
return true;
}
catch (CmisObjectNotFoundException e) {
return false;
}
} | [
"private",
"boolean",
"isExistCmisObject",
"(",
"String",
"path",
")",
"{",
"try",
"{",
"session",
".",
"getObjectByPath",
"(",
"path",
")",
";",
"return",
"true",
";",
"}",
"catch",
"(",
"CmisObjectNotFoundException",
"e",
")",
"{",
"return",
"false",
";",
... | Utility method for checking if CMIS object exists at defined path
@param path path for object
@return <code>true</code> if exists, <code>false</code> otherwise | [
"Utility",
"method",
"for",
"checking",
"if",
"CMIS",
"object",
"exists",
"at",
"defined",
"path"
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L629-L637 |
56,435 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.rename | private void rename(CmisObject object, String name){
Map<String, Object> newName = new HashMap<String, Object>();
newName.put("cmis:name", name);
object.updateProperties(newName);
} | java | private void rename(CmisObject object, String name){
Map<String, Object> newName = new HashMap<String, Object>();
newName.put("cmis:name", name);
object.updateProperties(newName);
} | [
"private",
"void",
"rename",
"(",
"CmisObject",
"object",
",",
"String",
"name",
")",
"{",
"Map",
"<",
"String",
",",
"Object",
">",
"newName",
"=",
"new",
"HashMap",
"<",
"String",
",",
"Object",
">",
"(",
")",
";",
"newName",
".",
"put",
"(",
"\"cm... | Utility method for renaming CMIS object
@param object CMIS object to rename
@param name new name | [
"Utility",
"method",
"for",
"renaming",
"CMIS",
"object"
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L644-L649 |
56,436 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisObject | private Document cmisObject( String id ) {
CmisObject cmisObject;
try {
cmisObject = session.getObject(id);
} catch (CmisObjectNotFoundException e) {
return null;
}
// object does not exist? return null
if (cmisObject == null) {
ret... | java | private Document cmisObject( String id ) {
CmisObject cmisObject;
try {
cmisObject = session.getObject(id);
} catch (CmisObjectNotFoundException e) {
return null;
}
// object does not exist? return null
if (cmisObject == null) {
ret... | [
"private",
"Document",
"cmisObject",
"(",
"String",
"id",
")",
"{",
"CmisObject",
"cmisObject",
";",
"try",
"{",
"cmisObject",
"=",
"session",
".",
"getObject",
"(",
"id",
")",
";",
"}",
"catch",
"(",
"CmisObjectNotFoundException",
"e",
")",
"{",
"return",
... | Converts CMIS object to JCR node.
@param id the identifier of the CMIS object
@return JCR node document. | [
"Converts",
"CMIS",
"object",
"to",
"JCR",
"node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L711-L738 |
56,437 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisFolder | private Document cmisFolder( CmisObject cmisObject ) {
Folder folder = (Folder)cmisObject;
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.OBJECT, folder.getId()));
ObjectType objectType = cmisObject.getType();
if (objectType.isBaseType()) {
writer.setPri... | java | private Document cmisFolder( CmisObject cmisObject ) {
Folder folder = (Folder)cmisObject;
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.OBJECT, folder.getId()));
ObjectType objectType = cmisObject.getType();
if (objectType.isBaseType()) {
writer.setPri... | [
"private",
"Document",
"cmisFolder",
"(",
"CmisObject",
"cmisObject",
")",
"{",
"Folder",
"folder",
"=",
"(",
"Folder",
")",
"cmisObject",
";",
"DocumentWriter",
"writer",
"=",
"newDocument",
"(",
"ObjectId",
".",
"toString",
"(",
"ObjectId",
".",
"Type",
".",... | Translates CMIS folder object to JCR node
@param cmisObject CMIS folder object
@return JCR node document. | [
"Translates",
"CMIS",
"folder",
"object",
"to",
"JCR",
"node"
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L746-L772 |
56,438 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisDocument | public Document cmisDocument( CmisObject cmisObject ) {
org.apache.chemistry.opencmis.client.api.Document doc = (org.apache.chemistry.opencmis.client.api.Document)cmisObject;
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.OBJECT, doc.getId()));
ObjectType objectType = cmisO... | java | public Document cmisDocument( CmisObject cmisObject ) {
org.apache.chemistry.opencmis.client.api.Document doc = (org.apache.chemistry.opencmis.client.api.Document)cmisObject;
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.OBJECT, doc.getId()));
ObjectType objectType = cmisO... | [
"public",
"Document",
"cmisDocument",
"(",
"CmisObject",
"cmisObject",
")",
"{",
"org",
".",
"apache",
".",
"chemistry",
".",
"opencmis",
".",
"client",
".",
"api",
".",
"Document",
"doc",
"=",
"(",
"org",
".",
"apache",
".",
"chemistry",
".",
"opencmis",
... | Translates cmis document object to JCR node.
@param cmisObject cmis document node
@return JCR node document. | [
"Translates",
"cmis",
"document",
"object",
"to",
"JCR",
"node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L780-L809 |
56,439 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisContent | private Document cmisContent( String id ) {
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.CONTENT, id));
org.apache.chemistry.opencmis.client.api.Document doc = (org.apache.chemistry.opencmis.client.api.Document)session.getObject(id);
writer.setPrimaryType(NodeType.NT_RESO... | java | private Document cmisContent( String id ) {
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.CONTENT, id));
org.apache.chemistry.opencmis.client.api.Document doc = (org.apache.chemistry.opencmis.client.api.Document)session.getObject(id);
writer.setPrimaryType(NodeType.NT_RESO... | [
"private",
"Document",
"cmisContent",
"(",
"String",
"id",
")",
"{",
"DocumentWriter",
"writer",
"=",
"newDocument",
"(",
"ObjectId",
".",
"toString",
"(",
"ObjectId",
".",
"Type",
".",
"CONTENT",
",",
"id",
")",
")",
";",
"org",
".",
"apache",
".",
"che... | Converts binary content into JCR node.
@param id the id of the CMIS document.
@return JCR node representation. | [
"Converts",
"binary",
"content",
"into",
"JCR",
"node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L817-L838 |
56,440 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisProperties | private void cmisProperties( CmisObject object,
DocumentWriter writer ) {
// convert properties
List<Property<?>> list = object.getProperties();
for (Property<?> property : list) {
String pname = properties.findJcrName(property.getId());
i... | java | private void cmisProperties( CmisObject object,
DocumentWriter writer ) {
// convert properties
List<Property<?>> list = object.getProperties();
for (Property<?> property : list) {
String pname = properties.findJcrName(property.getId());
i... | [
"private",
"void",
"cmisProperties",
"(",
"CmisObject",
"object",
",",
"DocumentWriter",
"writer",
")",
"{",
"// convert properties",
"List",
"<",
"Property",
"<",
"?",
">",
">",
"list",
"=",
"object",
".",
"getProperties",
"(",
")",
";",
"for",
"(",
"Proper... | Converts CMIS object's properties to JCR node properties.
@param object CMIS object
@param writer JCR node representation. | [
"Converts",
"CMIS",
"object",
"s",
"properties",
"to",
"JCR",
"node",
"properties",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L859-L869 |
56,441 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisChildren | private void cmisChildren( Folder folder,
DocumentWriter writer ) {
ItemIterable<CmisObject> it = folder.getChildren();
for (CmisObject obj : it) {
writer.addChild(obj.getId(), obj.getName());
}
} | java | private void cmisChildren( Folder folder,
DocumentWriter writer ) {
ItemIterable<CmisObject> it = folder.getChildren();
for (CmisObject obj : it) {
writer.addChild(obj.getId(), obj.getName());
}
} | [
"private",
"void",
"cmisChildren",
"(",
"Folder",
"folder",
",",
"DocumentWriter",
"writer",
")",
"{",
"ItemIterable",
"<",
"CmisObject",
">",
"it",
"=",
"folder",
".",
"getChildren",
"(",
")",
";",
"for",
"(",
"CmisObject",
"obj",
":",
"it",
")",
"{",
"... | Converts CMIS folder children to JCR node children
@param folder CMIS folder
@param writer JCR node representation | [
"Converts",
"CMIS",
"folder",
"children",
"to",
"JCR",
"node",
"children"
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L877-L883 |
56,442 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.cmisRepository | private Document cmisRepository() {
RepositoryInfo info = session.getRepositoryInfo();
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.REPOSITORY_INFO, ""));
writer.setPrimaryType(CmisLexicon.REPOSITORY);
writer.setId(REPOSITORY_INFO_ID);
// product name/ven... | java | private Document cmisRepository() {
RepositoryInfo info = session.getRepositoryInfo();
DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.REPOSITORY_INFO, ""));
writer.setPrimaryType(CmisLexicon.REPOSITORY);
writer.setId(REPOSITORY_INFO_ID);
// product name/ven... | [
"private",
"Document",
"cmisRepository",
"(",
")",
"{",
"RepositoryInfo",
"info",
"=",
"session",
".",
"getRepositoryInfo",
"(",
")",
";",
"DocumentWriter",
"writer",
"=",
"newDocument",
"(",
"ObjectId",
".",
"toString",
"(",
"ObjectId",
".",
"Type",
".",
"REP... | Translates CMIS repository information into Node.
@return node document. | [
"Translates",
"CMIS",
"repository",
"information",
"into",
"Node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L890-L903 |
56,443 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.jcrBinaryContent | private ContentStream jcrBinaryContent( Document document ) {
// pickup node properties
Document props = document.getDocument("properties").getDocument(JcrLexicon.Namespace.URI);
// extract binary value and content
Binary value = props.getBinary("data");
if (value == null) {
... | java | private ContentStream jcrBinaryContent( Document document ) {
// pickup node properties
Document props = document.getDocument("properties").getDocument(JcrLexicon.Namespace.URI);
// extract binary value and content
Binary value = props.getBinary("data");
if (value == null) {
... | [
"private",
"ContentStream",
"jcrBinaryContent",
"(",
"Document",
"document",
")",
"{",
"// pickup node properties",
"Document",
"props",
"=",
"document",
".",
"getDocument",
"(",
"\"properties\"",
")",
".",
"getDocument",
"(",
"JcrLexicon",
".",
"Namespace",
".",
"U... | Creates content stream using JCR node.
@param document JCR node representation
@return CMIS content stream object | [
"Creates",
"content",
"stream",
"using",
"JCR",
"node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L952-L973 |
56,444 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.importTypes | private void importTypes( List<Tree<ObjectType>> types,
NodeTypeManager typeManager,
NamespaceRegistry registry ) throws RepositoryException {
for (Tree<ObjectType> tree : types) {
importType(tree.getItem(), typeManager, registry);
... | java | private void importTypes( List<Tree<ObjectType>> types,
NodeTypeManager typeManager,
NamespaceRegistry registry ) throws RepositoryException {
for (Tree<ObjectType> tree : types) {
importType(tree.getItem(), typeManager, registry);
... | [
"private",
"void",
"importTypes",
"(",
"List",
"<",
"Tree",
"<",
"ObjectType",
">",
">",
"types",
",",
"NodeTypeManager",
"typeManager",
",",
"NamespaceRegistry",
"registry",
")",
"throws",
"RepositoryException",
"{",
"for",
"(",
"Tree",
"<",
"ObjectType",
">",
... | Import CMIS types to JCR repository.
@param types CMIS types
@param typeManager JCR type manager
@param registry
@throws RepositoryException if there is a problem importing the types | [
"Import",
"CMIS",
"types",
"to",
"JCR",
"repository",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L983-L990 |
56,445 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.importType | @SuppressWarnings( "unchecked" )
public void importType( ObjectType cmisType,
NodeTypeManager typeManager,
NamespaceRegistry registry ) throws RepositoryException {
// TODO: get namespace information and register
// registry.registerNamespace(c... | java | @SuppressWarnings( "unchecked" )
public void importType( ObjectType cmisType,
NodeTypeManager typeManager,
NamespaceRegistry registry ) throws RepositoryException {
// TODO: get namespace information and register
// registry.registerNamespace(c... | [
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"public",
"void",
"importType",
"(",
"ObjectType",
"cmisType",
",",
"NodeTypeManager",
"typeManager",
",",
"NamespaceRegistry",
"registry",
")",
"throws",
"RepositoryException",
"{",
"// TODO: get namespace information and... | Import given CMIS type to the JCR repository.
@param cmisType cmis object type
@param typeManager JCR type manager/
@param registry
@throws RepositoryException if there is a problem importing the types | [
"Import",
"given",
"CMIS",
"type",
"to",
"the",
"JCR",
"repository",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L1000-L1037 |
56,446 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.superTypes | private String[] superTypes( ObjectType cmisType ) {
if (cmisType.getBaseTypeId() == BaseTypeId.CMIS_FOLDER) {
return new String[] {JcrConstants.NT_FOLDER};
}
if (cmisType.getBaseTypeId() == BaseTypeId.CMIS_DOCUMENT) {
return new String[] {JcrConstants.NT_FILE};
... | java | private String[] superTypes( ObjectType cmisType ) {
if (cmisType.getBaseTypeId() == BaseTypeId.CMIS_FOLDER) {
return new String[] {JcrConstants.NT_FOLDER};
}
if (cmisType.getBaseTypeId() == BaseTypeId.CMIS_DOCUMENT) {
return new String[] {JcrConstants.NT_FILE};
... | [
"private",
"String",
"[",
"]",
"superTypes",
"(",
"ObjectType",
"cmisType",
")",
"{",
"if",
"(",
"cmisType",
".",
"getBaseTypeId",
"(",
")",
"==",
"BaseTypeId",
".",
"CMIS_FOLDER",
")",
"{",
"return",
"new",
"String",
"[",
"]",
"{",
"JcrConstants",
".",
... | Determines supertypes for the given CMIS type in terms of JCR.
@param cmisType given CMIS type
@return supertypes in JCR lexicon. | [
"Determines",
"supertypes",
"for",
"the",
"given",
"CMIS",
"type",
"in",
"terms",
"of",
"JCR",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L1045-L1055 |
56,447 | ModeShape/modeshape | connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java | CmisConnector.registerRepositoryInfoType | @SuppressWarnings( "unchecked" )
private void registerRepositoryInfoType( NodeTypeManager typeManager ) throws RepositoryException {
// create node type template
NodeTypeTemplate type = typeManager.createNodeTypeTemplate();
// convert CMIS type's attributes to node type template we have jus... | java | @SuppressWarnings( "unchecked" )
private void registerRepositoryInfoType( NodeTypeManager typeManager ) throws RepositoryException {
// create node type template
NodeTypeTemplate type = typeManager.createNodeTypeTemplate();
// convert CMIS type's attributes to node type template we have jus... | [
"@",
"SuppressWarnings",
"(",
"\"unchecked\"",
")",
"private",
"void",
"registerRepositoryInfoType",
"(",
"NodeTypeManager",
"typeManager",
")",
"throws",
"RepositoryException",
"{",
"// create node type template",
"NodeTypeTemplate",
"type",
"=",
"typeManager",
".",
"creat... | Defines node type for the repository info.
@param typeManager JCR node type manager.
@throws RepositoryException | [
"Defines",
"node",
"type",
"for",
"the",
"repository",
"info",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L1063-L1100 |
56,448 | ModeShape/modeshape | modeshape-jdbc-local/src/main/java/org/modeshape/jdbc/delegate/LocalRepositoryDelegate.java | LocalRepositoryDelegate.execute | @Override
public QueryResult execute( String query,
String language ) throws RepositoryException {
logger.trace("Executing query: {0}", query);
// Create the query ...
final Query jcrQuery = getLocalSession().getSession().getWorkspace().getQueryManager().cre... | java | @Override
public QueryResult execute( String query,
String language ) throws RepositoryException {
logger.trace("Executing query: {0}", query);
// Create the query ...
final Query jcrQuery = getLocalSession().getSession().getWorkspace().getQueryManager().cre... | [
"@",
"Override",
"public",
"QueryResult",
"execute",
"(",
"String",
"query",
",",
"String",
"language",
")",
"throws",
"RepositoryException",
"{",
"logger",
".",
"trace",
"(",
"\"Executing query: {0}\"",
",",
"query",
")",
";",
"// Create the query ...",
"final",
... | This execute method is used for redirection so that the JNDI implementation can control calling execute.
@see java.sql.Statement#execute(java.lang.String) | [
"This",
"execute",
"method",
"is",
"used",
"for",
"redirection",
"so",
"that",
"the",
"JNDI",
"implementation",
"can",
"control",
"calling",
"execute",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jdbc-local/src/main/java/org/modeshape/jdbc/delegate/LocalRepositoryDelegate.java#L120-L129 |
56,449 | ModeShape/modeshape | modeshape-jdbc/src/main/java/org/modeshape/jdbc/rest/ModeShapeRestClient.java | ModeShapeRestClient.getRepositories | public Repositories getRepositories() {
JSONRestClient.Response response = jsonRestClient.doGet();
if (!response.isOK()) {
throw new RuntimeException(JdbcI18n.invalidServerResponse.text(jsonRestClient.url(), response.asString()));
}
return new Repositories(response.json());
... | java | public Repositories getRepositories() {
JSONRestClient.Response response = jsonRestClient.doGet();
if (!response.isOK()) {
throw new RuntimeException(JdbcI18n.invalidServerResponse.text(jsonRestClient.url(), response.asString()));
}
return new Repositories(response.json());
... | [
"public",
"Repositories",
"getRepositories",
"(",
")",
"{",
"JSONRestClient",
".",
"Response",
"response",
"=",
"jsonRestClient",
".",
"doGet",
"(",
")",
";",
"if",
"(",
"!",
"response",
".",
"isOK",
"(",
")",
")",
"{",
"throw",
"new",
"RuntimeException",
... | Returns a list with all the available repositories.
@return a {@link Repositories} instance, never {@code null} | [
"Returns",
"a",
"list",
"with",
"all",
"the",
"available",
"repositories",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jdbc/src/main/java/org/modeshape/jdbc/rest/ModeShapeRestClient.java#L68-L74 |
56,450 | ModeShape/modeshape | modeshape-jdbc/src/main/java/org/modeshape/jdbc/rest/ModeShapeRestClient.java | ModeShapeRestClient.getWorkspaces | public Workspaces getWorkspaces( String repositoryName ) {
String url = jsonRestClient.appendToBaseURL(repositoryName);
JSONRestClient.Response response = jsonRestClient.doGet(url);
if (!response.isOK()) {
throw new RuntimeException(JdbcI18n.invalidServerResponse.text(url, response.a... | java | public Workspaces getWorkspaces( String repositoryName ) {
String url = jsonRestClient.appendToBaseURL(repositoryName);
JSONRestClient.Response response = jsonRestClient.doGet(url);
if (!response.isOK()) {
throw new RuntimeException(JdbcI18n.invalidServerResponse.text(url, response.a... | [
"public",
"Workspaces",
"getWorkspaces",
"(",
"String",
"repositoryName",
")",
"{",
"String",
"url",
"=",
"jsonRestClient",
".",
"appendToBaseURL",
"(",
"repositoryName",
")",
";",
"JSONRestClient",
".",
"Response",
"response",
"=",
"jsonRestClient",
".",
"doGet",
... | Returns all the workspaces for the named repository.
@param repositoryName a {@code String} the name of a repository; may not be {@code null}
@return a {@link Workspaces} instance; never {@code null} | [
"Returns",
"all",
"the",
"workspaces",
"for",
"the",
"named",
"repository",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jdbc/src/main/java/org/modeshape/jdbc/rest/ModeShapeRestClient.java#L96-L103 |
56,451 | ModeShape/modeshape | modeshape-jdbc/src/main/java/org/modeshape/jdbc/rest/ModeShapeRestClient.java | ModeShapeRestClient.queryPlan | public String queryPlan( String query,
String queryLanguage ) {
String url = jsonRestClient.appendToURL(QUERY_PLAN_METHOD);
String contentType = contentTypeForQueryLanguage(queryLanguage);
JSONRestClient.Response response = jsonRestClient.postStreamTextPlain(new Byte... | java | public String queryPlan( String query,
String queryLanguage ) {
String url = jsonRestClient.appendToURL(QUERY_PLAN_METHOD);
String contentType = contentTypeForQueryLanguage(queryLanguage);
JSONRestClient.Response response = jsonRestClient.postStreamTextPlain(new Byte... | [
"public",
"String",
"queryPlan",
"(",
"String",
"query",
",",
"String",
"queryLanguage",
")",
"{",
"String",
"url",
"=",
"jsonRestClient",
".",
"appendToURL",
"(",
"QUERY_PLAN_METHOD",
")",
";",
"String",
"contentType",
"=",
"contentTypeForQueryLanguage",
"(",
"qu... | Returns a string representation of a query plan in a given language.
@param query a {@code String}, never {@code null}
@param queryLanguage the language of the query, never {@code null}
@return a {@code String} description of the plan, never {@code null} | [
"Returns",
"a",
"string",
"representation",
"of",
"a",
"query",
"plan",
"in",
"a",
"given",
"language",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jdbc/src/main/java/org/modeshape/jdbc/rest/ModeShapeRestClient.java#L145-L155 |
56,452 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/SearchResults.java | SearchResults.getCardinality | public long getCardinality() {
if (pos > 0) {
return totalHits;
}
try {
EsResponse res = client.search(index, type, query);
Document hits = (Document) res.get("hits");
totalHits = hits.getInteger("total");
return totalHits;
} ca... | java | public long getCardinality() {
if (pos > 0) {
return totalHits;
}
try {
EsResponse res = client.search(index, type, query);
Document hits = (Document) res.get("hits");
totalHits = hits.getInteger("total");
return totalHits;
} ca... | [
"public",
"long",
"getCardinality",
"(",
")",
"{",
"if",
"(",
"pos",
">",
"0",
")",
"{",
"return",
"totalHits",
";",
"}",
"try",
"{",
"EsResponse",
"res",
"=",
"client",
".",
"search",
"(",
"index",
",",
"type",
",",
"query",
")",
";",
"Document",
... | Gets cardinality for this search request.
@return total hits matching search request. | [
"Gets",
"cardinality",
"for",
"this",
"search",
"request",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/SearchResults.java#L108-L120 |
56,453 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.convertArgumentClassesToPrimitives | public static List<Class<?>> convertArgumentClassesToPrimitives( Class<?>... arguments ) {
if (arguments == null || arguments.length == 0) return Collections.emptyList();
List<Class<?>> result = new ArrayList<Class<?>>(arguments.length);
for (Class<?> clazz : arguments) {
if (clazz =... | java | public static List<Class<?>> convertArgumentClassesToPrimitives( Class<?>... arguments ) {
if (arguments == null || arguments.length == 0) return Collections.emptyList();
List<Class<?>> result = new ArrayList<Class<?>>(arguments.length);
for (Class<?> clazz : arguments) {
if (clazz =... | [
"public",
"static",
"List",
"<",
"Class",
"<",
"?",
">",
">",
"convertArgumentClassesToPrimitives",
"(",
"Class",
"<",
"?",
">",
"...",
"arguments",
")",
"{",
"if",
"(",
"arguments",
"==",
"null",
"||",
"arguments",
".",
"length",
"==",
"0",
")",
"return... | Convert any argument classes to primitives.
@param arguments the list of argument classes.
@return the list of Class instances in which any classes that could be represented by primitives (e.g., Boolean) were
replaced with the primitive classes (e.g., Boolean.TYPE). | [
"Convert",
"any",
"argument",
"classes",
"to",
"primitives",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L102-L119 |
56,454 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.getClassName | public static String getClassName( final Class<?> clazz ) {
final String fullName = clazz.getName();
final int fullNameLength = fullName.length();
// Check for array ('[') or the class/interface marker ('L') ...
int numArrayDimensions = 0;
while (numArrayDimensions < fullNameLen... | java | public static String getClassName( final Class<?> clazz ) {
final String fullName = clazz.getName();
final int fullNameLength = fullName.length();
// Check for array ('[') or the class/interface marker ('L') ...
int numArrayDimensions = 0;
while (numArrayDimensions < fullNameLen... | [
"public",
"static",
"String",
"getClassName",
"(",
"final",
"Class",
"<",
"?",
">",
"clazz",
")",
"{",
"final",
"String",
"fullName",
"=",
"clazz",
".",
"getName",
"(",
")",
";",
"final",
"int",
"fullNameLength",
"=",
"fullName",
".",
"length",
"(",
")",... | Returns the name of the class. The result will be the fully-qualified class name, or the readable form for arrays and
primitive types.
@param clazz the class for which the class name is to be returned.
@return the readable name of the class. | [
"Returns",
"the",
"name",
"of",
"the",
"class",
".",
"The",
"result",
"will",
"be",
"the",
"fully",
"-",
"qualified",
"class",
"name",
"or",
"the",
"readable",
"form",
"for",
"arrays",
"and",
"primitive",
"types",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L128-L202 |
56,455 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.setValue | public static void setValue(Object instance, String fieldName, Object value) {
try {
Field f = findFieldRecursively(instance.getClass(), fieldName);
if (f == null)
throw new NoSuchMethodException("Cannot find field " + fieldName + " on " + instance.getClass() + " or super... | java | public static void setValue(Object instance, String fieldName, Object value) {
try {
Field f = findFieldRecursively(instance.getClass(), fieldName);
if (f == null)
throw new NoSuchMethodException("Cannot find field " + fieldName + " on " + instance.getClass() + " or super... | [
"public",
"static",
"void",
"setValue",
"(",
"Object",
"instance",
",",
"String",
"fieldName",
",",
"Object",
"value",
")",
"{",
"try",
"{",
"Field",
"f",
"=",
"findFieldRecursively",
"(",
"instance",
".",
"getClass",
"(",
")",
",",
"fieldName",
")",
";",
... | Sets the value of a field of an object instance via reflection
@param instance to inspect
@param fieldName name of field to set
@param value the value to set | [
"Sets",
"the",
"value",
"of",
"a",
"field",
"of",
"an",
"object",
"instance",
"via",
"reflection"
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L211-L221 |
56,456 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.findMethod | public static Method findMethod(Class<?> type, String methodName) {
try {
return type.getDeclaredMethod(methodName);
} catch (NoSuchMethodException e) {
if (type.equals(Object.class) || type.isInterface()) {
throw new RuntimeException(e);
}
... | java | public static Method findMethod(Class<?> type, String methodName) {
try {
return type.getDeclaredMethod(methodName);
} catch (NoSuchMethodException e) {
if (type.equals(Object.class) || type.isInterface()) {
throw new RuntimeException(e);
}
... | [
"public",
"static",
"Method",
"findMethod",
"(",
"Class",
"<",
"?",
">",
"type",
",",
"String",
"methodName",
")",
"{",
"try",
"{",
"return",
"type",
".",
"getDeclaredMethod",
"(",
"methodName",
")",
";",
"}",
"catch",
"(",
"NoSuchMethodException",
"e",
")... | Searches for a method with a given name in a class.
@param type a {@link Class} instance; never null
@param methodName the name of the method to search for; never null
@return a {@link Method} instance if the method is found | [
"Searches",
"for",
"a",
"method",
"with",
"a",
"given",
"name",
"in",
"a",
"class",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L249-L258 |
56,457 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.findMethods | public Method[] findMethods( Pattern methodNamePattern ) {
final Method[] allMethods = this.targetClass.getMethods();
final List<Method> result = new ArrayList<Method>();
for (int i = 0; i < allMethods.length; i++) {
final Method m = allMethods[i];
if (methodNamePattern.m... | java | public Method[] findMethods( Pattern methodNamePattern ) {
final Method[] allMethods = this.targetClass.getMethods();
final List<Method> result = new ArrayList<Method>();
for (int i = 0; i < allMethods.length; i++) {
final Method m = allMethods[i];
if (methodNamePattern.m... | [
"public",
"Method",
"[",
"]",
"findMethods",
"(",
"Pattern",
"methodNamePattern",
")",
"{",
"final",
"Method",
"[",
"]",
"allMethods",
"=",
"this",
".",
"targetClass",
".",
"getMethods",
"(",
")",
";",
"final",
"List",
"<",
"Method",
">",
"result",
"=",
... | Find the methods on the target class that matches the supplied method name.
@param methodNamePattern the regular expression pattern for the name of the method that is to be found.
@return the Method objects that have a matching name, or an empty array if there are no methods that have a matching name. | [
"Find",
"the",
"methods",
"on",
"the",
"target",
"class",
"that",
"matches",
"the",
"supplied",
"method",
"name",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L384-L394 |
56,458 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.invokeGetterMethodOnTarget | public Object invokeGetterMethodOnTarget( String javaPropertyName,
Object target )
throws NoSuchMethodException, SecurityException, IllegalArgumentException, IllegalAccessException,
InvocationTargetException {
String[] methodNamesArray = findMethodNa... | java | public Object invokeGetterMethodOnTarget( String javaPropertyName,
Object target )
throws NoSuchMethodException, SecurityException, IllegalArgumentException, IllegalAccessException,
InvocationTargetException {
String[] methodNamesArray = findMethodNa... | [
"public",
"Object",
"invokeGetterMethodOnTarget",
"(",
"String",
"javaPropertyName",
",",
"Object",
"target",
")",
"throws",
"NoSuchMethodException",
",",
"SecurityException",
",",
"IllegalArgumentException",
",",
"IllegalAccessException",
",",
"InvocationTargetException",
"{... | Find and execute the getter method on the target class for the supplied property name. If no such method is found, a
NoSuchMethodException is thrown.
@param javaPropertyName the name of the property whose getter is to be invoked, in the order they are to be tried
@param target the object on which the method is to be i... | [
"Find",
"and",
"execute",
"the",
"getter",
"method",
"on",
"the",
"target",
"class",
"for",
"the",
"supplied",
"property",
"name",
".",
"If",
"no",
"such",
"method",
"is",
"found",
"a",
"NoSuchMethodException",
"is",
"thrown",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L633-L647 |
56,459 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.setProperty | public void setProperty( Object target,
Property property,
Object value )
throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException {
CheckArg.isNotNull(target, "target");... | java | public void setProperty( Object target,
Property property,
Object value )
throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException {
CheckArg.isNotNull(target, "target");... | [
"public",
"void",
"setProperty",
"(",
"Object",
"target",
",",
"Property",
"property",
",",
"Object",
"value",
")",
"throws",
"SecurityException",
",",
"IllegalArgumentException",
",",
"NoSuchMethodException",
",",
"IllegalAccessException",
",",
"InvocationTargetException... | Set the property on the supplied target object to the specified value.
@param target the target on which the setter is to be called; may not be null
@param property the property that is to be set on the target
@param value the new value for the property
@throws NoSuchMethodException if a matching method is not found.
... | [
"Set",
"the",
"property",
"on",
"the",
"supplied",
"target",
"object",
"to",
"the",
"specified",
"value",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L1105-L1114 |
56,460 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.getProperty | public Object getProperty( Object target,
Property property )
throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException {
CheckArg.isNotNull(target, "target");
CheckArg.isNotNull(property, "... | java | public Object getProperty( Object target,
Property property )
throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException {
CheckArg.isNotNull(target, "target");
CheckArg.isNotNull(property, "... | [
"public",
"Object",
"getProperty",
"(",
"Object",
"target",
",",
"Property",
"property",
")",
"throws",
"SecurityException",
",",
"IllegalArgumentException",
",",
"NoSuchMethodException",
",",
"IllegalAccessException",
",",
"InvocationTargetException",
"{",
"CheckArg",
".... | Get current value for the property on the supplied target object.
@param target the target on which the setter is to be called; may not be null
@param property the property that is to be set on the target
@return the current value for the property; may be null
@throws NoSuchMethodException if a matching method is not ... | [
"Get",
"current",
"value",
"for",
"the",
"property",
"on",
"the",
"supplied",
"target",
"object",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L1128-L1136 |
56,461 | ModeShape/modeshape | modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java | Reflection.getPropertyAsString | public String getPropertyAsString( Object target,
Property property )
throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException {
Object value = getProperty(target, property);
String... | java | public String getPropertyAsString( Object target,
Property property )
throws SecurityException, IllegalArgumentException, NoSuchMethodException, IllegalAccessException,
InvocationTargetException {
Object value = getProperty(target, property);
String... | [
"public",
"String",
"getPropertyAsString",
"(",
"Object",
"target",
",",
"Property",
"property",
")",
"throws",
"SecurityException",
",",
"IllegalArgumentException",
",",
"NoSuchMethodException",
",",
"IllegalAccessException",
",",
"InvocationTargetException",
"{",
"Object"... | Get current value represented as a string for the property on the supplied target object.
@param target the target on which the setter is to be called; may not be null
@param property the property that is to be set on the target
@return the current value for the property; may be null
@throws NoSuchMethodException if a... | [
"Get",
"current",
"value",
"represented",
"as",
"a",
"string",
"for",
"the",
"property",
"on",
"the",
"supplied",
"target",
"object",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-common/src/main/java/org/modeshape/common/util/Reflection.java#L1150-L1158 |
56,462 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/cache/NodeKey.java | NodeKey.getSourceKey | public String getSourceKey() {
if (sourceKey == null) {
// Value is idempotent, so it's okay to do this without synchronizing ...
sourceKey = key.substring(SOURCE_START_INDEX, SOURCE_END_INDEX);
}
return sourceKey;
} | java | public String getSourceKey() {
if (sourceKey == null) {
// Value is idempotent, so it's okay to do this without synchronizing ...
sourceKey = key.substring(SOURCE_START_INDEX, SOURCE_END_INDEX);
}
return sourceKey;
} | [
"public",
"String",
"getSourceKey",
"(",
")",
"{",
"if",
"(",
"sourceKey",
"==",
"null",
")",
"{",
"// Value is idempotent, so it's okay to do this without synchronizing ...",
"sourceKey",
"=",
"key",
".",
"substring",
"(",
"SOURCE_START_INDEX",
",",
"SOURCE_END_INDEX",
... | Get the multi-character key uniquely identifying the repository's storage source in which this node appears.
@return the source key; never null and always contains at least one character | [
"Get",
"the",
"multi",
"-",
"character",
"key",
"uniquely",
"identifying",
"the",
"repository",
"s",
"storage",
"source",
"in",
"which",
"this",
"node",
"appears",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/cache/NodeKey.java#L151-L157 |
56,463 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/cache/NodeKey.java | NodeKey.getWorkspaceKey | public String getWorkspaceKey() {
if (workspaceKey == null) {
// Value is idempotent, so it's okay to do this without synchronizing ...
workspaceKey = key.substring(WORKSPACE_START_INDEX, WORKSPACE_END_INDEX);
}
return workspaceKey;
} | java | public String getWorkspaceKey() {
if (workspaceKey == null) {
// Value is idempotent, so it's okay to do this without synchronizing ...
workspaceKey = key.substring(WORKSPACE_START_INDEX, WORKSPACE_END_INDEX);
}
return workspaceKey;
} | [
"public",
"String",
"getWorkspaceKey",
"(",
")",
"{",
"if",
"(",
"workspaceKey",
"==",
"null",
")",
"{",
"// Value is idempotent, so it's okay to do this without synchronizing ...",
"workspaceKey",
"=",
"key",
".",
"substring",
"(",
"WORKSPACE_START_INDEX",
",",
"WORKSPAC... | Get the multi-character key uniquely identifying the workspace in which the node appears.
@return the workspace key; never null and always contains at least one character | [
"Get",
"the",
"multi",
"-",
"character",
"key",
"uniquely",
"identifying",
"the",
"workspace",
"in",
"which",
"the",
"node",
"appears",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/cache/NodeKey.java#L164-L170 |
56,464 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java | QueryBuilder.union | public QueryBuilder union() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.UNION;
this.firstQueryAll = false;
clear(false);
return this;
} | java | public QueryBuilder union() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.UNION;
this.firstQueryAll = false;
clear(false);
return this;
} | [
"public",
"QueryBuilder",
"union",
"(",
")",
"{",
"this",
".",
"firstQuery",
"=",
"query",
"(",
")",
";",
"this",
".",
"firstQuerySetOperation",
"=",
"Operation",
".",
"UNION",
";",
"this",
".",
"firstQueryAll",
"=",
"false",
";",
"clear",
"(",
"false",
... | Perform a UNION between the query as defined prior to this method and the query that will be defined following this method.
@return this builder object, for convenience in method chaining | [
"Perform",
"a",
"UNION",
"between",
"the",
"query",
"as",
"defined",
"prior",
"to",
"this",
"method",
"and",
"the",
"query",
"that",
"will",
"be",
"defined",
"following",
"this",
"method",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java#L621-L627 |
56,465 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java | QueryBuilder.unionAll | public QueryBuilder unionAll() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.UNION;
this.firstQueryAll = true;
clear(false);
return this;
} | java | public QueryBuilder unionAll() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.UNION;
this.firstQueryAll = true;
clear(false);
return this;
} | [
"public",
"QueryBuilder",
"unionAll",
"(",
")",
"{",
"this",
".",
"firstQuery",
"=",
"query",
"(",
")",
";",
"this",
".",
"firstQuerySetOperation",
"=",
"Operation",
".",
"UNION",
";",
"this",
".",
"firstQueryAll",
"=",
"true",
";",
"clear",
"(",
"false",
... | Perform a UNION ALL between the query as defined prior to this method and the query that will be defined following this
method.
@return this builder object, for convenience in method chaining | [
"Perform",
"a",
"UNION",
"ALL",
"between",
"the",
"query",
"as",
"defined",
"prior",
"to",
"this",
"method",
"and",
"the",
"query",
"that",
"will",
"be",
"defined",
"following",
"this",
"method",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java#L635-L641 |
56,466 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java | QueryBuilder.intersect | public QueryBuilder intersect() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.INTERSECT;
this.firstQueryAll = false;
clear(false);
return this;
} | java | public QueryBuilder intersect() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.INTERSECT;
this.firstQueryAll = false;
clear(false);
return this;
} | [
"public",
"QueryBuilder",
"intersect",
"(",
")",
"{",
"this",
".",
"firstQuery",
"=",
"query",
"(",
")",
";",
"this",
".",
"firstQuerySetOperation",
"=",
"Operation",
".",
"INTERSECT",
";",
"this",
".",
"firstQueryAll",
"=",
"false",
";",
"clear",
"(",
"fa... | Perform an INTERSECT between the query as defined prior to this method and the query that will be defined following this
method.
@return this builder object, for convenience in method chaining | [
"Perform",
"an",
"INTERSECT",
"between",
"the",
"query",
"as",
"defined",
"prior",
"to",
"this",
"method",
"and",
"the",
"query",
"that",
"will",
"be",
"defined",
"following",
"this",
"method",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java#L649-L655 |
56,467 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java | QueryBuilder.intersectAll | public QueryBuilder intersectAll() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.INTERSECT;
this.firstQueryAll = true;
clear(false);
return this;
} | java | public QueryBuilder intersectAll() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.INTERSECT;
this.firstQueryAll = true;
clear(false);
return this;
} | [
"public",
"QueryBuilder",
"intersectAll",
"(",
")",
"{",
"this",
".",
"firstQuery",
"=",
"query",
"(",
")",
";",
"this",
".",
"firstQuerySetOperation",
"=",
"Operation",
".",
"INTERSECT",
";",
"this",
".",
"firstQueryAll",
"=",
"true",
";",
"clear",
"(",
"... | Perform an INTERSECT ALL between the query as defined prior to this method and the query that will be defined following
this method.
@return this builder object, for convenience in method chaining | [
"Perform",
"an",
"INTERSECT",
"ALL",
"between",
"the",
"query",
"as",
"defined",
"prior",
"to",
"this",
"method",
"and",
"the",
"query",
"that",
"will",
"be",
"defined",
"following",
"this",
"method",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java#L663-L669 |
56,468 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java | QueryBuilder.except | public QueryBuilder except() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.EXCEPT;
this.firstQueryAll = false;
clear(false);
return this;
} | java | public QueryBuilder except() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.EXCEPT;
this.firstQueryAll = false;
clear(false);
return this;
} | [
"public",
"QueryBuilder",
"except",
"(",
")",
"{",
"this",
".",
"firstQuery",
"=",
"query",
"(",
")",
";",
"this",
".",
"firstQuerySetOperation",
"=",
"Operation",
".",
"EXCEPT",
";",
"this",
".",
"firstQueryAll",
"=",
"false",
";",
"clear",
"(",
"false",
... | Perform an EXCEPT between the query as defined prior to this method and the query that will be defined following this
method.
@return this builder object, for convenience in method chaining | [
"Perform",
"an",
"EXCEPT",
"between",
"the",
"query",
"as",
"defined",
"prior",
"to",
"this",
"method",
"and",
"the",
"query",
"that",
"will",
"be",
"defined",
"following",
"this",
"method",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java#L677-L683 |
56,469 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java | QueryBuilder.exceptAll | public QueryBuilder exceptAll() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.EXCEPT;
this.firstQueryAll = true;
clear(false);
return this;
} | java | public QueryBuilder exceptAll() {
this.firstQuery = query();
this.firstQuerySetOperation = Operation.EXCEPT;
this.firstQueryAll = true;
clear(false);
return this;
} | [
"public",
"QueryBuilder",
"exceptAll",
"(",
")",
"{",
"this",
".",
"firstQuery",
"=",
"query",
"(",
")",
";",
"this",
".",
"firstQuerySetOperation",
"=",
"Operation",
".",
"EXCEPT",
";",
"this",
".",
"firstQueryAll",
"=",
"true",
";",
"clear",
"(",
"false"... | Perform an EXCEPT ALL between the query as defined prior to this method and the query that will be defined following this
method.
@return this builder object, for convenience in method chaining | [
"Perform",
"an",
"EXCEPT",
"ALL",
"between",
"the",
"query",
"as",
"defined",
"prior",
"to",
"this",
"method",
"and",
"the",
"query",
"that",
"will",
"be",
"defined",
"following",
"this",
"method",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/QueryBuilder.java#L691-L697 |
56,470 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/spi/index/provider/IndexChangeAdapters.java | IndexChangeAdapters.forMultipleColumns | public static IndexChangeAdapter forMultipleColumns( ExecutionContext context,
NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> inde... | java | public static IndexChangeAdapter forMultipleColumns( ExecutionContext context,
NodeTypePredicate matcher,
String workspaceName,
ProvidedIndex<?> inde... | [
"public",
"static",
"IndexChangeAdapter",
"forMultipleColumns",
"(",
"ExecutionContext",
"context",
",",
"NodeTypePredicate",
"matcher",
",",
"String",
"workspaceName",
",",
"ProvidedIndex",
"<",
"?",
">",
"index",
",",
"Iterable",
"<",
"IndexChangeAdapter",
">",
"ada... | Creates a composite change adapter which handles the case when an index has multiple columns.
@param context the execution context; may not be null
@param matcher the node type matcher used to determine which nodes should be included in the index; may not be null
@param workspaceName the name of the workspace; may not... | [
"Creates",
"a",
"composite",
"change",
"adapter",
"which",
"handles",
"the",
"case",
"when",
"an",
"index",
"has",
"multiple",
"columns",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/spi/index/provider/IndexChangeAdapters.java#L63-L69 |
56,471 | ModeShape/modeshape | sequencers/modeshape-sequencer-audio/src/main/java/org/modeshape/sequencer/audio/AudioMetadata.java | AudioMetadata.checkSupportedAudio | private boolean checkSupportedAudio() {
AudioHeader header = audioFile.getAudioHeader();
bitrate = header.getBitRateAsNumber();
sampleRate = header.getSampleRateAsNumber();
channels = header.getChannels();
if (header.getChannels().toLowerCase().contains("stereo")) {
c... | java | private boolean checkSupportedAudio() {
AudioHeader header = audioFile.getAudioHeader();
bitrate = header.getBitRateAsNumber();
sampleRate = header.getSampleRateAsNumber();
channels = header.getChannels();
if (header.getChannels().toLowerCase().contains("stereo")) {
c... | [
"private",
"boolean",
"checkSupportedAudio",
"(",
")",
"{",
"AudioHeader",
"header",
"=",
"audioFile",
".",
"getAudioHeader",
"(",
")",
";",
"bitrate",
"=",
"header",
".",
"getBitRateAsNumber",
"(",
")",
";",
"sampleRate",
"=",
"header",
".",
"getSampleRateAsNum... | Parse tags common for all audio files. | [
"Parse",
"tags",
"common",
"for",
"all",
"audio",
"files",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/sequencers/modeshape-sequencer-audio/src/main/java/org/modeshape/sequencer/audio/AudioMetadata.java#L175-L215 |
56,472 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/index/local/LocalUniqueIndex.java | LocalUniqueIndex.create | static <T> LocalUniqueIndex<T> create( String name,
String workspaceName,
DB db,
Converter<T> converter,
BTreeKeySerializer<T> valueSerializer,
... | java | static <T> LocalUniqueIndex<T> create( String name,
String workspaceName,
DB db,
Converter<T> converter,
BTreeKeySerializer<T> valueSerializer,
... | [
"static",
"<",
"T",
">",
"LocalUniqueIndex",
"<",
"T",
">",
"create",
"(",
"String",
"name",
",",
"String",
"workspaceName",
",",
"DB",
"db",
",",
"Converter",
"<",
"T",
">",
"converter",
",",
"BTreeKeySerializer",
"<",
"T",
">",
"valueSerializer",
",",
... | Create a new index that allows only a single value for each unique key.
@param name the name of the index; may not be null or empty
@param workspaceName the name of the workspace; may not be null
@param db the database in which the index information is to be stored; may not be null
@param converter the converter from ... | [
"Create",
"a",
"new",
"index",
"that",
"allows",
"only",
"a",
"single",
"value",
"for",
"each",
"unique",
"key",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/index/local/LocalUniqueIndex.java#L48-L55 |
56,473 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/EsIndexColumn.java | EsIndexColumn.columnValue | protected Object columnValue(Object value) {
switch (type) {
case PATH:
case NAME:
case STRING:
case REFERENCE:
case SIMPLEREFERENCE:
case WEAKREFERENCE:
case URI:
return valueFactories.getStringFactory().create(... | java | protected Object columnValue(Object value) {
switch (type) {
case PATH:
case NAME:
case STRING:
case REFERENCE:
case SIMPLEREFERENCE:
case WEAKREFERENCE:
case URI:
return valueFactories.getStringFactory().create(... | [
"protected",
"Object",
"columnValue",
"(",
"Object",
"value",
")",
"{",
"switch",
"(",
"type",
")",
"{",
"case",
"PATH",
":",
"case",
"NAME",
":",
"case",
"STRING",
":",
"case",
"REFERENCE",
":",
"case",
"SIMPLEREFERENCE",
":",
"case",
"WEAKREFERENCE",
":"... | Converts representation of the given value using type conversation rules
between JCR type of this column and Elasticsearch core type of this column.
@param value value to be converted.
@return converted value. | [
"Converts",
"representation",
"of",
"the",
"given",
"value",
"using",
"type",
"conversation",
"rules",
"between",
"JCR",
"type",
"of",
"this",
"column",
"and",
"Elasticsearch",
"core",
"type",
"of",
"this",
"column",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/EsIndexColumn.java#L114-L129 |
56,474 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/EsIndexColumn.java | EsIndexColumn.cast | protected Object cast(Object value) {
switch (type) {
case STRING :
return valueFactories.getStringFactory().create(value);
case LONG :
return valueFactories.getLongFactory().create(value);
case NAME :
return valueFactories.getNa... | java | protected Object cast(Object value) {
switch (type) {
case STRING :
return valueFactories.getStringFactory().create(value);
case LONG :
return valueFactories.getLongFactory().create(value);
case NAME :
return valueFactories.getNa... | [
"protected",
"Object",
"cast",
"(",
"Object",
"value",
")",
"{",
"switch",
"(",
"type",
")",
"{",
"case",
"STRING",
":",
"return",
"valueFactories",
".",
"getStringFactory",
"(",
")",
".",
"create",
"(",
"value",
")",
";",
"case",
"LONG",
":",
"return",
... | Converts given value to the value of JCR type of this column.
@param value value to be converted.
@return converted value. | [
"Converts",
"given",
"value",
"to",
"the",
"value",
"of",
"JCR",
"type",
"of",
"this",
"column",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/EsIndexColumn.java#L154-L179 |
56,475 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.indexExists | public boolean indexExists(String name) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpHead head = new HttpHead(String.format("http://%s:%d/%s", host, port, name));
try {
CloseableHttpResponse response = client.execute(head);
return res... | java | public boolean indexExists(String name) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpHead head = new HttpHead(String.format("http://%s:%d/%s", host, port, name));
try {
CloseableHttpResponse response = client.execute(head);
return res... | [
"public",
"boolean",
"indexExists",
"(",
"String",
"name",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpHead",
"head",
"=",
"new",
"HttpHead",
"(",
"String",
".",
"format",
"(... | Tests for the index existence with specified name.
@param name the name of the index to test.
@return true if index with given name exists and false otherwise.
@throws IOException communication exception. | [
"Tests",
"for",
"the",
"index",
"existence",
"with",
"specified",
"name",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L60-L69 |
56,476 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.createIndex | public boolean createIndex(String name, String type, EsRequest mappings) throws IOException {
if (indexExists(name)) {
return true;
}
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s", host, port, name));... | java | public boolean createIndex(String name, String type, EsRequest mappings) throws IOException {
if (indexExists(name)) {
return true;
}
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s", host, port, name));... | [
"public",
"boolean",
"createIndex",
"(",
"String",
"name",
",",
"String",
"type",
",",
"EsRequest",
"mappings",
")",
"throws",
"IOException",
"{",
"if",
"(",
"indexExists",
"(",
"name",
")",
")",
"{",
"return",
"true",
";",
"}",
"CloseableHttpClient",
"clien... | Creates new index.
@param name the name of the index to test.
@param type index type
@param mappings field mapping definition.
@return true if index was created.
@throws IOException communication exception. | [
"Creates",
"new",
"index",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L80-L95 |
56,477 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.deleteIndex | public boolean deleteIndex(String name) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpDelete delete = new HttpDelete(String.format("http://%s:%d/%s", host, port, name));
try {
CloseableHttpResponse resp = client.execute(delete);
return... | java | public boolean deleteIndex(String name) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpDelete delete = new HttpDelete(String.format("http://%s:%d/%s", host, port, name));
try {
CloseableHttpResponse resp = client.execute(delete);
return... | [
"public",
"boolean",
"deleteIndex",
"(",
"String",
"name",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpDelete",
"delete",
"=",
"new",
"HttpDelete",
"(",
"String",
".",
"format"... | Deletes index.
@param name the name of the index to be deleted.
@return true if index was deleted.
@throws IOException | [
"Deletes",
"index",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L104-L113 |
56,478 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.storeDocument | public boolean storeDocument(String name, String type, String id,
EsRequest doc) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/%s/%s", host, port, name, type, id));
try {
String... | java | public boolean storeDocument(String name, String type, String id,
EsRequest doc) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/%s/%s", host, port, name, type, id));
try {
String... | [
"public",
"boolean",
"storeDocument",
"(",
"String",
"name",
",",
"String",
"type",
",",
"String",
"id",
",",
"EsRequest",
"doc",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"Http... | Indexes document.
@param name the name of the index.
@param type index type
@param id document id
@param doc document
@return true if document was indexed.
@throws IOException | [
"Indexes",
"document",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L125-L138 |
56,479 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.getDocument | public EsRequest getDocument(String name, String type, String id) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpGet method = new HttpGet(String.format("http://%s:%d/%s/%s/%s", host, port, name, type, id));
try {
CloseableHttpResponse resp = client... | java | public EsRequest getDocument(String name, String type, String id) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpGet method = new HttpGet(String.format("http://%s:%d/%s/%s/%s", host, port, name, type, id));
try {
CloseableHttpResponse resp = client... | [
"public",
"EsRequest",
"getDocument",
"(",
"String",
"name",
",",
"String",
"type",
",",
"String",
"id",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpGet",
"method",
"=",
"new... | Searches indexed document.
@param name index name.
@param type index type.
@param id document identifier.
@return document if it was found or null.
@throws IOException | [
"Searches",
"indexed",
"document",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L149-L168 |
56,480 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.deleteDocument | public boolean deleteDocument(String name, String type, String id) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpDelete delete = new HttpDelete(String.format("http://%s:%d/%s/%s/%s", host, port, name, type, id));
try {
return client.execute(delete... | java | public boolean deleteDocument(String name, String type, String id) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpDelete delete = new HttpDelete(String.format("http://%s:%d/%s/%s/%s", host, port, name, type, id));
try {
return client.execute(delete... | [
"public",
"boolean",
"deleteDocument",
"(",
"String",
"name",
",",
"String",
"type",
",",
"String",
"id",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpDelete",
"delete",
"=",
... | Deletes document.
@param name index name.
@param type index type.
@param id document id
@return true if it was deleted.
@throws IOException | [
"Deletes",
"document",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L179-L187 |
56,481 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.deleteAll | public void deleteAll(String name, String type) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/%s", host, port, name, type));
try {
EsRequest query = new EsRequest();
query.put("... | java | public void deleteAll(String name, String type) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/%s", host, port, name, type));
try {
EsRequest query = new EsRequest();
query.put("... | [
"public",
"void",
"deleteAll",
"(",
"String",
"name",
",",
"String",
"type",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpPost",
"method",
"=",
"new",
"HttpPost",
"(",
"String... | Deletes all documents.
@param name index name
@param type index type.
@throws IOException | [
"Deletes",
"all",
"documents",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L196-L213 |
56,482 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.flush | public void flush(String name) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/_flush", host, port, name));
try {
CloseableHttpResponse resp = client.execute(method);
int status =... | java | public void flush(String name) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/_flush", host, port, name));
try {
CloseableHttpResponse resp = client.execute(method);
int status =... | [
"public",
"void",
"flush",
"(",
"String",
"name",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpPost",
"method",
"=",
"new",
"HttpPost",
"(",
"String",
".",
"format",
"(",
"\... | Flushes index data.
@param name index name.
@throws IOException | [
"Flushes",
"index",
"data",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L221-L233 |
56,483 | ModeShape/modeshape | index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java | EsClient.search | public EsResponse search(String name, String type, EsRequest query) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/%s/_search", host, port, name, type));
try {
StringEntity requestEntity = n... | java | public EsResponse search(String name, String type, EsRequest query) throws IOException {
CloseableHttpClient client = HttpClients.createDefault();
HttpPost method = new HttpPost(String.format("http://%s:%d/%s/%s/_search", host, port, name, type));
try {
StringEntity requestEntity = n... | [
"public",
"EsResponse",
"search",
"(",
"String",
"name",
",",
"String",
"type",
",",
"EsRequest",
"query",
")",
"throws",
"IOException",
"{",
"CloseableHttpClient",
"client",
"=",
"HttpClients",
".",
"createDefault",
"(",
")",
";",
"HttpPost",
"method",
"=",
"... | Executes query.
@param name index name.
@param type index type.
@param query query to be executed
@return search results in json format.
@throws IOException | [
"Executes",
"query",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L264-L280 |
56,484 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/value/basic/AbstractPath.java | AbstractPath.doGetString | protected String doGetString( NamespaceRegistry namespaceRegistry,
TextEncoder encoder,
TextEncoder delimiterEncoder ) {
if (encoder == null) encoder = DEFAULT_ENCODER;
final String delimiter = delimiterEncoder != null ? delimiterEncode... | java | protected String doGetString( NamespaceRegistry namespaceRegistry,
TextEncoder encoder,
TextEncoder delimiterEncoder ) {
if (encoder == null) encoder = DEFAULT_ENCODER;
final String delimiter = delimiterEncoder != null ? delimiterEncode... | [
"protected",
"String",
"doGetString",
"(",
"NamespaceRegistry",
"namespaceRegistry",
",",
"TextEncoder",
"encoder",
",",
"TextEncoder",
"delimiterEncoder",
")",
"{",
"if",
"(",
"encoder",
"==",
"null",
")",
"encoder",
"=",
"DEFAULT_ENCODER",
";",
"final",
"String",
... | Method that creates the string representation. This method works two different ways depending upon whether the namespace
registry is provided.
@param namespaceRegistry
@param encoder
@param delimiterEncoder
@return this path as a string | [
"Method",
"that",
"creates",
"the",
"string",
"representation",
".",
"This",
"method",
"works",
"two",
"different",
"ways",
"depending",
"upon",
"whether",
"the",
"namespace",
"registry",
"is",
"provided",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/value/basic/AbstractPath.java#L227-L251 |
56,485 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/JcrLockManager.java | JcrLockManager.lock | public Lock lock( AbstractJcrNode node,
boolean isDeep,
boolean isSessionScoped,
long timeoutHint,
String ownerInfo )
throws LockException, AccessDeniedException, InvalidItemStateException, RepositoryException {
if (... | java | public Lock lock( AbstractJcrNode node,
boolean isDeep,
boolean isSessionScoped,
long timeoutHint,
String ownerInfo )
throws LockException, AccessDeniedException, InvalidItemStateException, RepositoryException {
if (... | [
"public",
"Lock",
"lock",
"(",
"AbstractJcrNode",
"node",
",",
"boolean",
"isDeep",
",",
"boolean",
"isSessionScoped",
",",
"long",
"timeoutHint",
",",
"String",
"ownerInfo",
")",
"throws",
"LockException",
",",
"AccessDeniedException",
",",
"InvalidItemStateException... | Attempt to obtain a lock on the supplied node.
@param node the node; may not be null
@param isDeep true if the lock should be a deep lock
@param isSessionScoped true if the lock should be scoped to the session
@param timeoutHint desired lock timeout in seconds (servers are free to ignore this value); specify {@link Lo... | [
"Attempt",
"to",
"obtain",
"a",
"lock",
"on",
"the",
"supplied",
"node",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/JcrLockManager.java#L256-L277 |
56,486 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/xpath/XPathParser.java | XPathParser.removeQuotes | protected String removeQuotes( String text ) {
assert text != null;
if (text.length() > 2) {
char first = text.charAt(0);
// Need to remove these only if they are paired ...
if (first == '"' || first == '\'') {
int indexOfLast = text.length() - 1;
... | java | protected String removeQuotes( String text ) {
assert text != null;
if (text.length() > 2) {
char first = text.charAt(0);
// Need to remove these only if they are paired ...
if (first == '"' || first == '\'') {
int indexOfLast = text.length() - 1;
... | [
"protected",
"String",
"removeQuotes",
"(",
"String",
"text",
")",
"{",
"assert",
"text",
"!=",
"null",
";",
"if",
"(",
"text",
".",
"length",
"(",
")",
">",
"2",
")",
"{",
"char",
"first",
"=",
"text",
".",
"charAt",
"(",
"0",
")",
";",
"// Need t... | Remove any leading and trailing single-quotes or double-quotes from the supplied text.
@param text the input text; may not be null
@return the text without leading and trailing quotes, or <code>text</code> if there were no square brackets or quotes | [
"Remove",
"any",
"leading",
"and",
"trailing",
"single",
"-",
"quotes",
"or",
"double",
"-",
"quotes",
"from",
"the",
"supplied",
"text",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/xpath/XPathParser.java#L747-L761 |
56,487 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/BackupDocumentWriter.java | BackupDocumentWriter.write | public void write( Document document ) {
assert document != null;
++count;
++totalCount;
if (count > maxDocumentsPerFile) {
// Close the stream (we'll open a new one later in the method) ...
close();
count = 1;
}
try {
if (s... | java | public void write( Document document ) {
assert document != null;
++count;
++totalCount;
if (count > maxDocumentsPerFile) {
// Close the stream (we'll open a new one later in the method) ...
close();
count = 1;
}
try {
if (s... | [
"public",
"void",
"write",
"(",
"Document",
"document",
")",
"{",
"assert",
"document",
"!=",
"null",
";",
"++",
"count",
";",
"++",
"totalCount",
";",
"if",
"(",
"count",
">",
"maxDocumentsPerFile",
")",
"{",
"// Close the stream (we'll open a new one later in th... | Append the supplied document to the files.
@param document the document to be written; may not be null | [
"Append",
"the",
"supplied",
"document",
"to",
"the",
"files",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/BackupDocumentWriter.java#L71-L98 |
56,488 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java | Query.constrainedBy | public Query constrainedBy( Constraint constraint ) {
return new Query(source, constraint, orderings(), columns, getLimits(), distinct);
} | java | public Query constrainedBy( Constraint constraint ) {
return new Query(source, constraint, orderings(), columns, getLimits(), distinct);
} | [
"public",
"Query",
"constrainedBy",
"(",
"Constraint",
"constraint",
")",
"{",
"return",
"new",
"Query",
"(",
"source",
",",
"constraint",
",",
"orderings",
"(",
")",
",",
"columns",
",",
"getLimits",
"(",
")",
",",
"distinct",
")",
";",
"}"
] | Create a copy of this query, but one that uses the supplied constraint.
@param constraint the constraint that should be used; never null
@return the copy of the query that uses the supplied constraint; never null | [
"Create",
"a",
"copy",
"of",
"this",
"query",
"but",
"one",
"that",
"uses",
"the",
"supplied",
"constraint",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java#L177-L179 |
56,489 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java | Query.orderedBy | public Query orderedBy( List<Ordering> orderings ) {
return new Query(source, constraint, orderings, columns, getLimits(), distinct);
} | java | public Query orderedBy( List<Ordering> orderings ) {
return new Query(source, constraint, orderings, columns, getLimits(), distinct);
} | [
"public",
"Query",
"orderedBy",
"(",
"List",
"<",
"Ordering",
">",
"orderings",
")",
"{",
"return",
"new",
"Query",
"(",
"source",
",",
"constraint",
",",
"orderings",
",",
"columns",
",",
"getLimits",
"(",
")",
",",
"distinct",
")",
";",
"}"
] | Create a copy of this query, but one whose results should be ordered by the supplied orderings.
@param orderings the result ordering specification that should be used; never null
@return the copy of the query that uses the supplied ordering; never null | [
"Create",
"a",
"copy",
"of",
"this",
"query",
"but",
"one",
"whose",
"results",
"should",
"be",
"ordered",
"by",
"the",
"supplied",
"orderings",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java#L187-L189 |
56,490 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java | Query.returning | public Query returning( List<Column> columns ) {
return new Query(source, constraint, orderings(), columns, getLimits(), distinct);
} | java | public Query returning( List<Column> columns ) {
return new Query(source, constraint, orderings(), columns, getLimits(), distinct);
} | [
"public",
"Query",
"returning",
"(",
"List",
"<",
"Column",
">",
"columns",
")",
"{",
"return",
"new",
"Query",
"(",
"source",
",",
"constraint",
",",
"orderings",
"(",
")",
",",
"columns",
",",
"getLimits",
"(",
")",
",",
"distinct",
")",
";",
"}"
] | Create a copy of this query, but that returns results with the supplied columns.
@param columns the columns of the results; may not be null
@return the copy of the query returning the supplied result columns; never null | [
"Create",
"a",
"copy",
"of",
"this",
"query",
"but",
"that",
"returns",
"results",
"with",
"the",
"supplied",
"columns",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java#L209-L211 |
56,491 | ModeShape/modeshape | modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java | Query.adding | public Query adding( Column... columns ) {
List<Column> newColumns = null;
if (this.columns != null) {
newColumns = new ArrayList<Column>(this.columns);
for (Column column : columns) {
newColumns.add(column);
}
} else {
newColumns =... | java | public Query adding( Column... columns ) {
List<Column> newColumns = null;
if (this.columns != null) {
newColumns = new ArrayList<Column>(this.columns);
for (Column column : columns) {
newColumns.add(column);
}
} else {
newColumns =... | [
"public",
"Query",
"adding",
"(",
"Column",
"...",
"columns",
")",
"{",
"List",
"<",
"Column",
">",
"newColumns",
"=",
"null",
";",
"if",
"(",
"this",
".",
"columns",
"!=",
"null",
")",
"{",
"newColumns",
"=",
"new",
"ArrayList",
"<",
"Column",
">",
... | Create a copy of this query, but that returns results that include the columns specified by this query as well as the
supplied columns.
@param columns the additional columns that should be included in the the results; may not be null
@return the copy of the query returning the supplied result columns; never null | [
"Create",
"a",
"copy",
"of",
"this",
"query",
"but",
"that",
"returns",
"results",
"that",
"include",
"the",
"columns",
"specified",
"by",
"this",
"query",
"as",
"well",
"as",
"the",
"supplied",
"columns",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-jcr/src/main/java/org/modeshape/jcr/query/model/Query.java#L240-L251 |
56,492 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.getCredentials | private void getCredentials() {
jcrService.getUserName(new BaseCallback<String>() {
@Override
public void onSuccess(String name) {
showMainForm(name);
}
});
} | java | private void getCredentials() {
jcrService.getUserName(new BaseCallback<String>() {
@Override
public void onSuccess(String name) {
showMainForm(name);
}
});
} | [
"private",
"void",
"getCredentials",
"(",
")",
"{",
"jcrService",
".",
"getUserName",
"(",
"new",
"BaseCallback",
"<",
"String",
">",
"(",
")",
"{",
"@",
"Override",
"public",
"void",
"onSuccess",
"(",
"String",
"name",
")",
"{",
"showMainForm",
"(",
"name... | Checks user's credentials. | [
"Checks",
"user",
"s",
"credentials",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L94-L101 |
56,493 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.loadNodeSpecifiedByURL | public void loadNodeSpecifiedByURL() {
repositoriesList.select(jcrURL.getRepository(), jcrURL.getWorkspace(), jcrURL.getPath(), true);
} | java | public void loadNodeSpecifiedByURL() {
repositoriesList.select(jcrURL.getRepository(), jcrURL.getWorkspace(), jcrURL.getPath(), true);
} | [
"public",
"void",
"loadNodeSpecifiedByURL",
"(",
")",
"{",
"repositoriesList",
".",
"select",
"(",
"jcrURL",
".",
"getRepository",
"(",
")",
",",
"jcrURL",
".",
"getWorkspace",
"(",
")",
",",
"jcrURL",
".",
"getPath",
"(",
")",
",",
"true",
")",
";",
"}"... | Reconstructs URL and points browser to the requested node path. | [
"Reconstructs",
"URL",
"and",
"points",
"browser",
"to",
"the",
"requested",
"node",
"path",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L106-L108 |
56,494 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.showMainForm | public void showMainForm(String userName) {
align();
changeUserName(userName);
mainForm.addMember(header);
mainForm.addMember(repositoryHeader);
mainForm.addMember(viewPort);
mainForm.addMember(strut(30));
mainForm.addMember(footer);
setLayou... | java | public void showMainForm(String userName) {
align();
changeUserName(userName);
mainForm.addMember(header);
mainForm.addMember(repositoryHeader);
mainForm.addMember(viewPort);
mainForm.addMember(strut(30));
mainForm.addMember(footer);
setLayou... | [
"public",
"void",
"showMainForm",
"(",
"String",
"userName",
")",
"{",
"align",
"(",
")",
";",
"changeUserName",
"(",
"userName",
")",
";",
"mainForm",
".",
"addMember",
"(",
"header",
")",
";",
"mainForm",
".",
"addMember",
"(",
"repositoryHeader",
")",
"... | Shows main page for the logged in user.
@param userName the name of the user. | [
"Shows",
"main",
"page",
"for",
"the",
"logged",
"in",
"user",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L133-L149 |
56,495 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.changeRepositoryInURL | public void changeRepositoryInURL(String name, boolean changeHistory) {
jcrURL.setRepository(name);
if (changeHistory) {
htmlHistory.newItem(jcrURL.toString(), false);
}
} | java | public void changeRepositoryInURL(String name, boolean changeHistory) {
jcrURL.setRepository(name);
if (changeHistory) {
htmlHistory.newItem(jcrURL.toString(), false);
}
} | [
"public",
"void",
"changeRepositoryInURL",
"(",
"String",
"name",
",",
"boolean",
"changeHistory",
")",
"{",
"jcrURL",
".",
"setRepository",
"(",
"name",
")",
";",
"if",
"(",
"changeHistory",
")",
"{",
"htmlHistory",
".",
"newItem",
"(",
"jcrURL",
".",
"toSt... | Changes repository name in URL displayed by browser.
@param name the name of the repository.
@param changeHistory if true store URL changes in history. | [
"Changes",
"repository",
"name",
"in",
"URL",
"displayed",
"by",
"browser",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L250-L255 |
56,496 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.changeWorkspaceInURL | public void changeWorkspaceInURL(String name, boolean changeHistory) {
jcrURL.setWorkspace(name);
if (changeHistory) {
htmlHistory.newItem(jcrURL.toString(), false);
}
} | java | public void changeWorkspaceInURL(String name, boolean changeHistory) {
jcrURL.setWorkspace(name);
if (changeHistory) {
htmlHistory.newItem(jcrURL.toString(), false);
}
} | [
"public",
"void",
"changeWorkspaceInURL",
"(",
"String",
"name",
",",
"boolean",
"changeHistory",
")",
"{",
"jcrURL",
".",
"setWorkspace",
"(",
"name",
")",
";",
"if",
"(",
"changeHistory",
")",
"{",
"htmlHistory",
".",
"newItem",
"(",
"jcrURL",
".",
"toStri... | Changes workspace in the URL displayed by browser.
@param name the name of the repository.
@param changeHistory if true store URL changes in browser's history. | [
"Changes",
"workspace",
"in",
"the",
"URL",
"displayed",
"by",
"browser",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L263-L268 |
56,497 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.changePathInURL | public void changePathInURL(String path, boolean changeHistory) {
jcrURL.setPath(path);
if (changeHistory) {
htmlHistory.newItem(jcrURL.toString(), false);
}
} | java | public void changePathInURL(String path, boolean changeHistory) {
jcrURL.setPath(path);
if (changeHistory) {
htmlHistory.newItem(jcrURL.toString(), false);
}
} | [
"public",
"void",
"changePathInURL",
"(",
"String",
"path",
",",
"boolean",
"changeHistory",
")",
"{",
"jcrURL",
".",
"setPath",
"(",
"path",
")",
";",
"if",
"(",
"changeHistory",
")",
"{",
"htmlHistory",
".",
"newItem",
"(",
"jcrURL",
".",
"toString",
"("... | Changes node path in the URL displayed by browser.
@param path the path to the node.
@param changeHistory if true store URL changes in browser's history. | [
"Changes",
"node",
"path",
"in",
"the",
"URL",
"displayed",
"by",
"browser",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L276-L281 |
56,498 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.showRepositories | public void showRepositories(Collection<RepositoryName> names) {
repositoriesList.show(names);
display(repositoriesList);
this.hideRepository();
} | java | public void showRepositories(Collection<RepositoryName> names) {
repositoriesList.show(names);
display(repositoriesList);
this.hideRepository();
} | [
"public",
"void",
"showRepositories",
"(",
"Collection",
"<",
"RepositoryName",
">",
"names",
")",
"{",
"repositoriesList",
".",
"show",
"(",
"names",
")",
";",
"display",
"(",
"repositoriesList",
")",
";",
"this",
".",
"hideRepository",
"(",
")",
";",
"}"
] | Displays list of availables repositories.
@param names names of repositories. | [
"Displays",
"list",
"of",
"availables",
"repositories",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L294-L298 |
56,499 | ModeShape/modeshape | web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java | Console.displayContent | public void displayContent(String repository, String workspace, String path,
boolean changeHistory) {
contents.show(repository, workspace, path, changeHistory);
displayRepository(repository);
display(contents);
changeRepositoryInURL(repository, changeHistory);
} | java | public void displayContent(String repository, String workspace, String path,
boolean changeHistory) {
contents.show(repository, workspace, path, changeHistory);
displayRepository(repository);
display(contents);
changeRepositoryInURL(repository, changeHistory);
} | [
"public",
"void",
"displayContent",
"(",
"String",
"repository",
",",
"String",
"workspace",
",",
"String",
"path",
",",
"boolean",
"changeHistory",
")",
"{",
"contents",
".",
"show",
"(",
"repository",
",",
"workspace",
",",
"path",
",",
"changeHistory",
")",... | Displays node for the given repository, workspace and path.
@param repository the name of the repository.
@param workspace the name of workspace.
@param path the path to the node.
@param changeHistory store changes in browser history. | [
"Displays",
"node",
"for",
"the",
"given",
"repository",
"workspace",
"and",
"path",
"."
] | 794cfdabb67a90f24629c4fff0424a6125f8f95b | https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/web/modeshape-web-explorer/src/main/java/org/modeshape/web/client/Console.java#L308-L314 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.