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 | partition stringclasses 1
value |
|---|---|---|---|---|---|---|---|---|---|---|---|
aeshell/aesh-extensions | aesh/src/main/java/org/aesh/extensions/less/SimpleFileParser.java | SimpleFileParser.setFile | public void setFile(File file) throws IOException {
if(!file.isFile())
throw new IllegalArgumentException(file+" must be a file.");
else {
if(file.getName().endsWith("gz"))
initGzReader(file);
else
initReader(file);
}
} | java | public void setFile(File file) throws IOException {
if(!file.isFile())
throw new IllegalArgumentException(file+" must be a file.");
else {
if(file.getName().endsWith("gz"))
initGzReader(file);
else
initReader(file);
}
} | [
"public",
"void",
"setFile",
"(",
"File",
"file",
")",
"throws",
"IOException",
"{",
"if",
"(",
"!",
"file",
".",
"isFile",
"(",
")",
")",
"throw",
"new",
"IllegalArgumentException",
"(",
"file",
"+",
"\" must be a file.\"",
")",
";",
"else",
"{",
"if",
... | Read from a specified file. Also supports gzipped files.
@param file File
@throws IOException | [
"Read",
"from",
"a",
"specified",
"file",
".",
"Also",
"supports",
"gzipped",
"files",
"."
] | 3838ce46ed3771eb2ee6934303500f01a558e9ca | https://github.com/aeshell/aesh-extensions/blob/3838ce46ed3771eb2ee6934303500f01a558e9ca/aesh/src/main/java/org/aesh/extensions/less/SimpleFileParser.java#L65-L74 | train |
aeshell/aesh-extensions | aesh/src/main/java/org/aesh/extensions/less/SimpleFileParser.java | SimpleFileParser.setFileFromAJar | public void setFileFromAJar(String fileName) {
InputStream is = this.getClass().getResourceAsStream(fileName);
if(is != null) {
this.fileName = fileName;
reader = new InputStreamReader(is);
}
} | java | public void setFileFromAJar(String fileName) {
InputStream is = this.getClass().getResourceAsStream(fileName);
if(is != null) {
this.fileName = fileName;
reader = new InputStreamReader(is);
}
} | [
"public",
"void",
"setFileFromAJar",
"(",
"String",
"fileName",
")",
"{",
"InputStream",
"is",
"=",
"this",
".",
"getClass",
"(",
")",
".",
"getResourceAsStream",
"(",
"fileName",
")",
";",
"if",
"(",
"is",
"!=",
"null",
")",
"{",
"this",
".",
"fileName"... | Read a file resouce located in a jar
@param fileName name | [
"Read",
"a",
"file",
"resouce",
"located",
"in",
"a",
"jar"
] | 3838ce46ed3771eb2ee6934303500f01a558e9ca | https://github.com/aeshell/aesh-extensions/blob/3838ce46ed3771eb2ee6934303500f01a558e9ca/aesh/src/main/java/org/aesh/extensions/less/SimpleFileParser.java#L91-L97 | train |
Zappos/zappos-json | src/main/java/com/zappos/json/JsonReaderCodeGenerator.java | JsonReaderCodeGenerator.getTypeInfo | private TypeInfo getTypeInfo(Map<String, TypeInfo> typeMaps, String path, Class<?> superType) {
TypeInfo typeInfo = typeMaps.get(path);
if (typeInfo == null) {
typeInfo = new TypeInfo(superType);
typeMaps.put(path, typeInfo);
}
return typeInfo;
} | java | private TypeInfo getTypeInfo(Map<String, TypeInfo> typeMaps, String path, Class<?> superType) {
TypeInfo typeInfo = typeMaps.get(path);
if (typeInfo == null) {
typeInfo = new TypeInfo(superType);
typeMaps.put(path, typeInfo);
}
return typeInfo;
} | [
"private",
"TypeInfo",
"getTypeInfo",
"(",
"Map",
"<",
"String",
",",
"TypeInfo",
">",
"typeMaps",
",",
"String",
"path",
",",
"Class",
"<",
"?",
">",
"superType",
")",
"{",
"TypeInfo",
"typeInfo",
"=",
"typeMaps",
".",
"get",
"(",
"path",
")",
";",
"i... | Get the TypeInfo object from specified path or return the new one if it does not exist.
@param typeMaps
@param path
@param superType
@return | [
"Get",
"the",
"TypeInfo",
"object",
"from",
"specified",
"path",
"or",
"return",
"the",
"new",
"one",
"if",
"it",
"does",
"not",
"exist",
"."
] | 340633f5db75c2e09ce49bfc3e5f67e8823f5a37 | https://github.com/Zappos/zappos-json/blob/340633f5db75c2e09ce49bfc3e5f67e8823f5a37/src/main/java/com/zappos/json/JsonReaderCodeGenerator.java#L354-L364 | train |
Jasig/spring-portlet-contrib | spring-security-portlet-contrib/src/main/java/org/jasig/springframework/security/portlet/authentication/PortletAuthenticationProcessingFilter.java | PortletAuthenticationProcessingFilter.successfulAuthentication | protected void successfulAuthentication(PortletRequest request, PortletResponse response,
Authentication authResult) {
if (logger.isDebugEnabled()) {
logger.debug("Authentication success: " + authResult);
}
SecurityContextHolder.getContext().setAuthentication(authResult);... | java | protected void successfulAuthentication(PortletRequest request, PortletResponse response,
Authentication authResult) {
if (logger.isDebugEnabled()) {
logger.debug("Authentication success: " + authResult);
}
SecurityContextHolder.getContext().setAuthentication(authResult);... | [
"protected",
"void",
"successfulAuthentication",
"(",
"PortletRequest",
"request",
",",
"PortletResponse",
"response",
",",
"Authentication",
"authResult",
")",
"{",
"if",
"(",
"logger",
".",
"isDebugEnabled",
"(",
")",
")",
"{",
"logger",
".",
"debug",
"(",
"\"... | Puts the Authentication instance returned by the
authentication manager into the secure context.
@param request a {@link javax.portlet.PortletRequest} object.
@param response a {@link javax.portlet.PortletResponse} object.
@param authResult a {@link org.springframework.security.core.Authentication} object. | [
"Puts",
"the",
"Authentication",
"instance",
"returned",
"by",
"the",
"authentication",
"manager",
"into",
"the",
"secure",
"context",
"."
] | 719240fa268ddc69900ce9775d9cad3b9c543c6b | https://github.com/Jasig/spring-portlet-contrib/blob/719240fa268ddc69900ce9775d9cad3b9c543c6b/spring-security-portlet-contrib/src/main/java/org/jasig/springframework/security/portlet/authentication/PortletAuthenticationProcessingFilter.java#L214-L224 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java | SettingsApi.deleteTemplatesWithHttpInfo | public ApiResponse<Templates> deleteTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = deleteTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<Templates> deleteTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = deleteTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"Templates",
">",
"deleteTemplatesWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"deleteTemplatesValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Typ... | Delete Templates.
deleteTemplates
@return ApiResponse<Templates>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Delete",
"Templates",
".",
"deleteTemplates"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java#L133-L137 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java | SettingsApi.getApiEndpointsWithHttpInfo | public ApiResponse<ApiEndpointsSuccess> getApiEndpointsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getApiEndpointsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<ApiEndpointsSuccess>(){}.getType();
return apiClient.execute(call, localVarReturnType... | java | public ApiResponse<ApiEndpointsSuccess> getApiEndpointsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getApiEndpointsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<ApiEndpointsSuccess>(){}.getType();
return apiClient.execute(call, localVarReturnType... | [
"public",
"ApiResponse",
"<",
"ApiEndpointsSuccess",
">",
"getApiEndpointsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getApiEndpointsValidateBeforeCall",
"(",
"null",
",",
"null",
")",
"... | Get apiEndpoints.
Get api-endpoints
@return ApiResponse<ApiEndpointsSuccess>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"apiEndpoints",
".",
"Get",
"api",
"-",
"endpoints"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java#L246-L250 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java | SettingsApi.getTemplatesWithHttpInfo | public ApiResponse<Templates> getTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<Templates> getTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"Templates",
">",
"getTemplatesWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getTemplatesValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
... | Get Templates.
getTemplates
@return ApiResponse<Templates>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"Templates",
".",
"getTemplates"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java#L359-L363 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java | SettingsApi.postApiEndpointsWithHttpInfo | public ApiResponse<ApiPostEndpointsSuccess> postApiEndpointsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postApiEndpointsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<ApiPostEndpointsSuccess>(){}.getType();
return apiClient.execute(call, localVar... | java | public ApiResponse<ApiPostEndpointsSuccess> postApiEndpointsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postApiEndpointsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<ApiPostEndpointsSuccess>(){}.getType();
return apiClient.execute(call, localVar... | [
"public",
"ApiResponse",
"<",
"ApiPostEndpointsSuccess",
">",
"postApiEndpointsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postApiEndpointsValidateBeforeCall",
"(",
"null",
",",
"null",
")... | Post apiEndpoints.
Post api-endpoints
@return ApiResponse<ApiPostEndpointsSuccess>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"apiEndpoints",
".",
"Post",
"api",
"-",
"endpoints"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java#L472-L476 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java | SettingsApi.postTemplatesWithHttpInfo | public ApiResponse<Templates> postTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<Templates> postTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"Templates",
">",
"postTemplatesWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postTemplatesValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
... | Post Templates.
postTemplates
@return ApiResponse<Templates>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"Templates",
".",
"postTemplates"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java#L585-L589 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java | SettingsApi.putTemplatesWithHttpInfo | public ApiResponse<Templates> putTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = putTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<Templates> putTemplatesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = putTemplatesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<Templates>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"Templates",
">",
"putTemplatesWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"putTemplatesValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
... | Put Templates.
putTemplates
@return ApiResponse<Templates>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Put",
"Templates",
".",
"putTemplates"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SettingsApi.java#L698-L702 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SessionApi.java | SessionApi.getLogoutWithHttpInfo | public ApiResponse<GetLogout> getLogoutWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getLogoutValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetLogout>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetLogout> getLogoutWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getLogoutValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetLogout>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetLogout",
">",
"getLogoutWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getLogoutValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
"local... | Logout user
Logout the user by deleting the session and removing the associated cookie.
@return ApiResponse<GetLogout>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Logout",
"user",
"Logout",
"the",
"user",
"by",
"deleting",
"the",
"session",
"and",
"removing",
"the",
"associated",
"cookie",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SessionApi.java#L262-L266 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SessionApi.java | SessionApi.initProvisioningWithHttpInfo | public ApiResponse<ApiSuccessResponse> initProvisioningWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = initProvisioningValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<ApiSuccessResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType... | java | public ApiResponse<ApiSuccessResponse> initProvisioningWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = initProvisioningValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<ApiSuccessResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType... | [
"public",
"ApiResponse",
"<",
"ApiSuccessResponse",
">",
"initProvisioningWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"initProvisioningValidateBeforeCall",
"(",
"null",
",",
"null",
")",
... | Init Session
The GET operation will init user session.
@return ApiResponse<ApiSuccessResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Init",
"Session",
"The",
"GET",
"operation",
"will",
"init",
"user",
"session",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SessionApi.java#L375-L379 | train |
qzagarese/hyaline-dto | hyaline-dto/src/main/java/org/hyalinedto/api/Hyaline.java | Hyaline.dtoFromScratch | public static <T> T dtoFromScratch(T entity, DTO dtoTemplate) throws HyalineException {
return dtoFromScratch(entity, dtoTemplate, "Hyaline$Proxy$" + System.currentTimeMillis());
} | java | public static <T> T dtoFromScratch(T entity, DTO dtoTemplate) throws HyalineException {
return dtoFromScratch(entity, dtoTemplate, "Hyaline$Proxy$" + System.currentTimeMillis());
} | [
"public",
"static",
"<",
"T",
">",
"T",
"dtoFromScratch",
"(",
"T",
"entity",
",",
"DTO",
"dtoTemplate",
")",
"throws",
"HyalineException",
"{",
"return",
"dtoFromScratch",
"(",
"entity",
",",
"dtoTemplate",
",",
"\"Hyaline$Proxy$\"",
"+",
"System",
".",
"curr... | It lets you create a new DTO from scratch. This means that any annotation
from JAXB, Jackson or whatever serialization framework you are using on
your entity T will be ignored. The only annotation-based configuration
that will be used is the one you are defining in this invocation.
@param <T>
the generic type
@param e... | [
"It",
"lets",
"you",
"create",
"a",
"new",
"DTO",
"from",
"scratch",
".",
"This",
"means",
"that",
"any",
"annotation",
"from",
"JAXB",
"Jackson",
"or",
"whatever",
"serialization",
"framework",
"you",
"are",
"using",
"on",
"your",
"entity",
"T",
"will",
"... | 3392de5b7f93cdb3a1c53aa977ee682c141df5f4 | https://github.com/qzagarese/hyaline-dto/blob/3392de5b7f93cdb3a1c53aa977ee682c141df5f4/hyaline-dto/src/main/java/org/hyalinedto/api/Hyaline.java#L77-L79 | train |
qzagarese/hyaline-dto | hyaline-dto/src/main/java/org/hyalinedto/api/Hyaline.java | Hyaline.dtoFromScratch | public static <T> T dtoFromScratch(T entity, DTO dtoTemplate, String proxyClassName) throws HyalineException {
try {
return createDTO(entity, dtoTemplate, true, proxyClassName);
} catch (CannotInstantiateProxyException | DTODefinitionException e) {
e.printStackTrace();
throw new HyalineException();
}
} | java | public static <T> T dtoFromScratch(T entity, DTO dtoTemplate, String proxyClassName) throws HyalineException {
try {
return createDTO(entity, dtoTemplate, true, proxyClassName);
} catch (CannotInstantiateProxyException | DTODefinitionException e) {
e.printStackTrace();
throw new HyalineException();
}
} | [
"public",
"static",
"<",
"T",
">",
"T",
"dtoFromScratch",
"(",
"T",
"entity",
",",
"DTO",
"dtoTemplate",
",",
"String",
"proxyClassName",
")",
"throws",
"HyalineException",
"{",
"try",
"{",
"return",
"createDTO",
"(",
"entity",
",",
"dtoTemplate",
",",
"true... | It lets you create a new DTO from scratch. This means that any annotation
for JAXB, Jackson or whatever serialization framework you are using on
your entity T will be ignored. The only annotation-based configuration
that will be used is the one you are defining in this invocation.
@param <T>
the generic type
@param en... | [
"It",
"lets",
"you",
"create",
"a",
"new",
"DTO",
"from",
"scratch",
".",
"This",
"means",
"that",
"any",
"annotation",
"for",
"JAXB",
"Jackson",
"or",
"whatever",
"serialization",
"framework",
"you",
"are",
"using",
"on",
"your",
"entity",
"T",
"will",
"b... | 3392de5b7f93cdb3a1c53aa977ee682c141df5f4 | https://github.com/qzagarese/hyaline-dto/blob/3392de5b7f93cdb3a1c53aa977ee682c141df5f4/hyaline-dto/src/main/java/org/hyalinedto/api/Hyaline.java#L105-L112 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SamlSettingsApi.java | SamlSettingsApi.getEnabledWithHttpInfo | public ApiResponse<GetEnabledResponse> getEnabledWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getEnabledValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetEnabledResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetEnabledResponse> getEnabledWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getEnabledValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetEnabledResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetEnabledResponse",
">",
"getEnabledWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getEnabledValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type... | Get SAML state.
Returns SAML current state.
@return ApiResponse<GetEnabledResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"SAML",
"state",
".",
"Returns",
"SAML",
"current",
"state",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SamlSettingsApi.java#L386-L390 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SamlSettingsApi.java | SamlSettingsApi.getLocationsWithHttpInfo | public ApiResponse<GetLocationResponse> getLocationsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getLocationsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetLocationResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
... | java | public ApiResponse<GetLocationResponse> getLocationsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getLocationsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetLocationResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
... | [
"public",
"ApiResponse",
"<",
"GetLocationResponse",
">",
"getLocationsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getLocationsValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
... | Get exist locations.
Returns exist locations.
@return ApiResponse<GetLocationResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"exist",
"locations",
".",
"Returns",
"exist",
"locations",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SamlSettingsApi.java#L499-L503 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SamlSettingsApi.java | SamlSettingsApi.postLocationWithHttpInfo | public ApiResponse<PostLocationResponse> postLocationWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postLocationValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostLocationResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
... | java | public ApiResponse<PostLocationResponse> postLocationWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postLocationValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostLocationResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
... | [
"public",
"ApiResponse",
"<",
"PostLocationResponse",
">",
"postLocationWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postLocationValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
... | Set main settings.
Change global settings.
@return ApiResponse<PostLocationResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Set",
"main",
"settings",
".",
"Change",
"global",
"settings",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SamlSettingsApi.java#L885-L889 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java | StatisticsApi.checkMigrateConflictsWithHttpInfo | public ApiResponse<GetSubResponse> checkMigrateConflictsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = checkMigrateConflictsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetSubResponse>(){}.getType();
return apiClient.execute(call, localVarReturnTy... | java | public ApiResponse<GetSubResponse> checkMigrateConflictsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = checkMigrateConflictsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetSubResponse>(){}.getType();
return apiClient.execute(call, localVarReturnTy... | [
"public",
"ApiResponse",
"<",
"GetSubResponse",
">",
"checkMigrateConflictsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"checkMigrateConflictsValidateBeforeCall",
"(",
"null",
",",
"null",
"... | Get migrate check for conflicts.
Get migrate check for conflicts
@return ApiResponse<GetSubResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"migrate",
"check",
"for",
"conflicts",
".",
"Get",
"migrate",
"check",
"for",
"conflicts"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java#L138-L142 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java | StatisticsApi.checkPostMigrateStatisticWithHttpInfo | public ApiResponse<CheckPostMigrateStatistic> checkPostMigrateStatisticWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = checkPostMigrateStatisticValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<CheckPostMigrateStatistic>(){}.getType();
return apiClient.... | java | public ApiResponse<CheckPostMigrateStatistic> checkPostMigrateStatisticWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = checkPostMigrateStatisticValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<CheckPostMigrateStatistic>(){}.getType();
return apiClient.... | [
"public",
"ApiResponse",
"<",
"CheckPostMigrateStatistic",
">",
"checkPostMigrateStatisticWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"checkPostMigrateStatisticValidateBeforeCall",
"(",
"null",
... | Post statistic migrate.
Post statistic migrate
@return ApiResponse<CheckPostMigrateStatistic>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"statistic",
"migrate",
".",
"Post",
"statistic",
"migrate"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java#L251-L255 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java | StatisticsApi.getExportStatisticDefinitionsWithHttpInfo | public ApiResponse<GetExportStatisticDefinitions> getExportStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getExportStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetExportStatisticDefinitions>(){}.getType();
r... | java | public ApiResponse<GetExportStatisticDefinitions> getExportStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getExportStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetExportStatisticDefinitions>(){}.getType();
r... | [
"public",
"ApiResponse",
"<",
"GetExportStatisticDefinitions",
">",
"getExportStatisticDefinitionsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getExportStatisticDefinitionsValidateBeforeCall",
"(",... | Get export statistic definitions.
Get export statistic definitions
@return ApiResponse<GetExportStatisticDefinitions>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"export",
"statistic",
"definitions",
".",
"Get",
"export",
"statistic",
"definitions"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java#L610-L614 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java | StatisticsApi.getStatisticDefinitionsWithHttpInfo | public ApiResponse<GetStatisticDefinitionsResponse> getStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetStatisticDefinitionsResponse>(){}.getType();
return ap... | java | public ApiResponse<GetStatisticDefinitionsResponse> getStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetStatisticDefinitionsResponse>(){}.getType();
return ap... | [
"public",
"ApiResponse",
"<",
"GetStatisticDefinitionsResponse",
">",
"getStatisticDefinitionsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getStatisticDefinitionsValidateBeforeCall",
"(",
"null",... | Get statistic definitions.
Returns statistic definitions records.
@return ApiResponse<GetStatisticDefinitionsResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"statistic",
"definitions",
".",
"Returns",
"statistic",
"definitions",
"records",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java#L723-L727 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java | StatisticsApi.postImportStatisticDefinitionsWithHttpInfo | public ApiResponse<PostImportStatisticDefinitions> postImportStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postImportStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostImportStatisticDefinitions>(){}.getType();
... | java | public ApiResponse<PostImportStatisticDefinitions> postImportStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postImportStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostImportStatisticDefinitions>(){}.getType();
... | [
"public",
"ApiResponse",
"<",
"PostImportStatisticDefinitions",
">",
"postImportStatisticDefinitionsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postImportStatisticDefinitionsValidateBeforeCall",
"... | Post import statistic definitions.
Post import statistic definitions
@return ApiResponse<PostImportStatisticDefinitions>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"import",
"statistic",
"definitions",
".",
"Post",
"import",
"statistic",
"definitions"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java#L836-L840 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java | StatisticsApi.postStatisticDefinitionsWithHttpInfo | public ApiResponse<GetStatisticDefinitionsResponse> postStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetStatisticDefinitionsResponse>(){}.getType();
return ... | java | public ApiResponse<GetStatisticDefinitionsResponse> postStatisticDefinitionsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postStatisticDefinitionsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetStatisticDefinitionsResponse>(){}.getType();
return ... | [
"public",
"ApiResponse",
"<",
"GetStatisticDefinitionsResponse",
">",
"postStatisticDefinitionsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postStatisticDefinitionsValidateBeforeCall",
"(",
"null... | Post statistic definitions.
Returns statistic definitions records.
@return ApiResponse<GetStatisticDefinitionsResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"statistic",
"definitions",
".",
"Returns",
"statistic",
"definitions",
"records",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/StatisticsApi.java#L949-L953 | train |
greenjoe/sergeants | src/main/java/pl/joegreen/sergeants/framework/queue/QueueConfiguration.java | QueueConfiguration.customGame | public static QueueConfiguration customGame(boolean force, String gameId, int team) {
return new CustomGameQueueConfiguration(force, gameId, team);
} | java | public static QueueConfiguration customGame(boolean force, String gameId, int team) {
return new CustomGameQueueConfiguration(force, gameId, team);
} | [
"public",
"static",
"QueueConfiguration",
"customGame",
"(",
"boolean",
"force",
",",
"String",
"gameId",
",",
"int",
"team",
")",
"{",
"return",
"new",
"CustomGameQueueConfiguration",
"(",
"force",
",",
"gameId",
",",
"team",
")",
";",
"}"
] | Joins custom game.
@param force indicates if player should vote for "force start"
@param gameId identifier of the game to join (displayed in browser URL when starting custom game)
@param team number of team that bot will join in the custom game | [
"Joins",
"custom",
"game",
"."
] | db624bcea8597843210f138b82bc4a26b3ec92ca | https://github.com/greenjoe/sergeants/blob/db624bcea8597843210f138b82bc4a26b3ec92ca/src/main/java/pl/joegreen/sergeants/framework/queue/QueueConfiguration.java#L52-L54 | train |
Jasig/spring-portlet-contrib | spring-webmvc-portlet-contrib/src/main/java/org/jasig/springframework/web/portlet/support/PortletRequestContextUtils.java | PortletRequestContextUtils.getPortletApplicationContext | public static PortletApplicationContext getPortletApplicationContext(
PortletRequest request, PortletContext portletContext) throws IllegalStateException {
PortletApplicationContext portletApplicationContext = (PortletApplicationContext) request.getAttribute(
ContribDispatcherPortle... | java | public static PortletApplicationContext getPortletApplicationContext(
PortletRequest request, PortletContext portletContext) throws IllegalStateException {
PortletApplicationContext portletApplicationContext = (PortletApplicationContext) request.getAttribute(
ContribDispatcherPortle... | [
"public",
"static",
"PortletApplicationContext",
"getPortletApplicationContext",
"(",
"PortletRequest",
"request",
",",
"PortletContext",
"portletContext",
")",
"throws",
"IllegalStateException",
"{",
"PortletApplicationContext",
"portletApplicationContext",
"=",
"(",
"PortletApp... | Look for the PortletApplicationContext associated with the DispatcherPortlet
that has initiated request processing, and for the global context if none
was found associated with the current request. This method is useful to
allow components outside the framework, such as JSP tag handlers,
to access the most specific app... | [
"Look",
"for",
"the",
"PortletApplicationContext",
"associated",
"with",
"the",
"DispatcherPortlet",
"that",
"has",
"initiated",
"request",
"processing",
"and",
"for",
"the",
"global",
"context",
"if",
"none",
"was",
"found",
"associated",
"with",
"the",
"current",
... | 719240fa268ddc69900ce9775d9cad3b9c543c6b | https://github.com/Jasig/spring-portlet-contrib/blob/719240fa268ddc69900ce9775d9cad3b9c543c6b/spring-webmvc-portlet-contrib/src/main/java/org/jasig/springframework/web/portlet/support/PortletRequestContextUtils.java#L70-L83 | train |
Jasig/spring-portlet-contrib | spring-webmvc-portlet-contrib/src/main/java/org/jasig/springframework/web/portlet/support/PortletRequestContextUtils.java | PortletRequestContextUtils.getWebApplicationContext | public static ApplicationContext getWebApplicationContext(
PortletRequest request, PortletContext portletContext) throws IllegalStateException {
PortletApplicationContext portletApplicationContext = (PortletApplicationContext) request.getAttribute(
ContribDispatcherPortlet.PORTLET_A... | java | public static ApplicationContext getWebApplicationContext(
PortletRequest request, PortletContext portletContext) throws IllegalStateException {
PortletApplicationContext portletApplicationContext = (PortletApplicationContext) request.getAttribute(
ContribDispatcherPortlet.PORTLET_A... | [
"public",
"static",
"ApplicationContext",
"getWebApplicationContext",
"(",
"PortletRequest",
"request",
",",
"PortletContext",
"portletContext",
")",
"throws",
"IllegalStateException",
"{",
"PortletApplicationContext",
"portletApplicationContext",
"=",
"(",
"PortletApplicationCon... | Look for the PortletApplicationContext associated with the DispatcherPortlet
that has initiated request processing, for the global portlet context if none
was found associated with the current request, and for the global context if no
global portlet context was found. This method is useful to
allow components outside t... | [
"Look",
"for",
"the",
"PortletApplicationContext",
"associated",
"with",
"the",
"DispatcherPortlet",
"that",
"has",
"initiated",
"request",
"processing",
"for",
"the",
"global",
"portlet",
"context",
"if",
"none",
"was",
"found",
"associated",
"with",
"the",
"curren... | 719240fa268ddc69900ce9775d9cad3b9c543c6b | https://github.com/Jasig/spring-portlet-contrib/blob/719240fa268ddc69900ce9775d9cad3b9c543c6b/spring-webmvc-portlet-contrib/src/main/java/org/jasig/springframework/web/portlet/support/PortletRequestContextUtils.java#L100-L118 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/ProvisioningApi.java | ProvisioningApi.initializeWithCode | public void initializeWithCode(String authCode, String redirectUri) throws ProvisioningApiException {
initialize(null, authCode, redirectUri);
} | java | public void initializeWithCode(String authCode, String redirectUri) throws ProvisioningApiException {
initialize(null, authCode, redirectUri);
} | [
"public",
"void",
"initializeWithCode",
"(",
"String",
"authCode",
",",
"String",
"redirectUri",
")",
"throws",
"ProvisioningApiException",
"{",
"initialize",
"(",
"null",
",",
"authCode",
",",
"redirectUri",
")",
";",
"}"
] | Initialize the API with an code from the auth service.
@param authCode the code.
@param redirectUri the redirect uri used in the original code request.
@throws ProvisioningApiException if the call is unsuccessful. | [
"Initialize",
"the",
"API",
"with",
"an",
"code",
"from",
"the",
"auth",
"service",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/ProvisioningApi.java#L106-L108 | train |
greenjoe/sergeants | src/main/java/pl/joegreen/sergeants/framework/model/api/UpdatableGameState.java | UpdatableGameState.update | public UpdatableGameState update(GameUpdateApiResponse gameUpdateData) {
return new UpdatableGameState(
gameUpdateData.getTurn(), startData, MapPatcher.patch(gameUpdateData.getMapDiff(), rawMapArray),
MapPatcher.patch(gameUpdateData.getCitiesDiff(), rawCitiesArray),
... | java | public UpdatableGameState update(GameUpdateApiResponse gameUpdateData) {
return new UpdatableGameState(
gameUpdateData.getTurn(), startData, MapPatcher.patch(gameUpdateData.getMapDiff(), rawMapArray),
MapPatcher.patch(gameUpdateData.getCitiesDiff(), rawCitiesArray),
... | [
"public",
"UpdatableGameState",
"update",
"(",
"GameUpdateApiResponse",
"gameUpdateData",
")",
"{",
"return",
"new",
"UpdatableGameState",
"(",
"gameUpdateData",
".",
"getTurn",
"(",
")",
",",
"startData",
",",
"MapPatcher",
".",
"patch",
"(",
"gameUpdateData",
".",... | Updates game state from previous turn with new information received from server. The method only works fine if
updates are applied in sequence, as server is only sending map differences in update messages. | [
"Updates",
"game",
"state",
"from",
"previous",
"turn",
"with",
"new",
"information",
"received",
"from",
"server",
".",
"The",
"method",
"only",
"works",
"fine",
"if",
"updates",
"are",
"applied",
"in",
"sequence",
"as",
"server",
"is",
"only",
"sending",
"... | db624bcea8597843210f138b82bc4a26b3ec92ca | https://github.com/greenjoe/sergeants/blob/db624bcea8597843210f138b82bc4a26b3ec92ca/src/main/java/pl/joegreen/sergeants/framework/model/api/UpdatableGameState.java#L58-L65 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/MusicOnHoldApi.java | MusicOnHoldApi.getMOHFilesWithHttpInfo | public ApiResponse<GetMOHFilesResponse> getMOHFilesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getMOHFilesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetMOHFilesResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetMOHFilesResponse> getMOHFilesWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getMOHFilesValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetMOHFilesResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetMOHFilesResponse",
">",
"getMOHFilesWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getMOHFilesValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"T... | Get WAV files for MOH.
Returns exist WAV files.
@return ApiResponse<GetMOHFilesResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"WAV",
"files",
"for",
"MOH",
".",
"Returns",
"exist",
"WAV",
"files",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/MusicOnHoldApi.java#L260-L264 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/MusicOnHoldApi.java | MusicOnHoldApi.getMOHSettingsWithHttpInfo | public ApiResponse<GetMOHSettings> getMOHSettingsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getMOHSettingsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetMOHSettings>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetMOHSettings> getMOHSettingsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getMOHSettingsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetMOHSettings>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetMOHSettings",
">",
"getMOHSettingsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getMOHSettingsValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"... | Get exist setting.
Returns exist setting from MOH.
@return ApiResponse<GetMOHSettings>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"exist",
"setting",
".",
"Returns",
"exist",
"setting",
"from",
"MOH",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/MusicOnHoldApi.java#L373-L377 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java | OperationsApi.checkInactivityWithHttpInfo | public ApiResponse<PostCheckInactivity> checkInactivityWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = checkInactivityValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostCheckInactivity>(){}.getType();
return apiClient.execute(call, localVarReturnType... | java | public ApiResponse<PostCheckInactivity> checkInactivityWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = checkInactivityValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostCheckInactivity>(){}.getType();
return apiClient.execute(call, localVarReturnType... | [
"public",
"ApiResponse",
"<",
"PostCheckInactivity",
">",
"checkInactivityWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"checkInactivityValidateBeforeCall",
"(",
"null",
",",
"null",
")",
"... | Inactivity.
Inactivity.
@return ApiResponse<PostCheckInactivity>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Inactivity",
".",
"Inactivity",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java#L140-L144 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java | OperationsApi.getSubWithHttpInfo | public ApiResponse<GetSubResponse> getSubWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getSubValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetSubResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetSubResponse> getSubWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getSubValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetSubResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetSubResponse",
">",
"getSubWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getSubValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
"localV... | Get sub.
Sub
@return ApiResponse<GetSubResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"sub",
".",
"Sub"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java#L376-L380 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java | OperationsApi.postImportWithHttpInfo | public ApiResponse<PostImportResponse> postImportWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postImportValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostImportResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<PostImportResponse> postImportWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postImportValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostImportResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"PostImportResponse",
">",
"postImportWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postImportValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type... | PostImport.
postImport
@return ApiResponse<PostImportResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"PostImport",
".",
"postImport"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java#L910-L914 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java | OperationsApi.postUsersWithHttpInfo | public ApiResponse<PostUsers> postUsersWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postUsersValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostUsers>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<PostUsers> postUsersWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postUsersValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostUsers>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"PostUsers",
">",
"postUsersWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postUsersValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
"local... | Post users.
postUsers
@return ApiResponse<PostUsers>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"users",
".",
"postUsers"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java#L1023-L1027 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java | OperationsApi.postValidateImportWithHttpInfo | public ApiResponse<PostValidateImportResponse> postValidateImportWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postValidateImportValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostValidateImportResponse>(){}.getType();
return apiClient.execute(call... | java | public ApiResponse<PostValidateImportResponse> postValidateImportWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = postValidateImportValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PostValidateImportResponse>(){}.getType();
return apiClient.execute(call... | [
"public",
"ApiResponse",
"<",
"PostValidateImportResponse",
">",
"postValidateImportWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"postValidateImportValidateBeforeCall",
"(",
"null",
",",
"null... | Post Validate Import.
post validate import
@return ApiResponse<PostValidateImportResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Post",
"Validate",
"Import",
".",
"post",
"validate",
"import"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java#L1136-L1140 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java | OperationsApi.putUsersWithHttpInfo | public ApiResponse<PutUsers> putUsersWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = putUsersValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PutUsers>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<PutUsers> putUsersWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = putUsersValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<PutUsers>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"PutUsers",
">",
"putUsersWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"putUsersValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
"localVar... | Put users.
putUsers
@return ApiResponse<PutUsers>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Put",
"users",
".",
"putUsers"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/OperationsApi.java#L1249-L1253 | train |
Jasig/spring-portlet-contrib | spring-webmvc-portlet-contrib/src/main/java/org/jasig/springframework/web/portlet/context/PortletContextLoader.java | PortletContextLoader.determineContextClass | protected Class<?> determineContextClass(PortletContext portletContext) {
String contextClassName = portletContext.getInitParameter(CONTEXT_CLASS_PARAM);
if (contextClassName != null) {
try {
return ClassUtils.forName(contextClassName, ClassUtils.getDefaultClassLoader());
... | java | protected Class<?> determineContextClass(PortletContext portletContext) {
String contextClassName = portletContext.getInitParameter(CONTEXT_CLASS_PARAM);
if (contextClassName != null) {
try {
return ClassUtils.forName(contextClassName, ClassUtils.getDefaultClassLoader());
... | [
"protected",
"Class",
"<",
"?",
">",
"determineContextClass",
"(",
"PortletContext",
"portletContext",
")",
"{",
"String",
"contextClassName",
"=",
"portletContext",
".",
"getInitParameter",
"(",
"CONTEXT_CLASS_PARAM",
")",
";",
"if",
"(",
"contextClassName",
"!=",
... | Return the PortletApplicationContext implementation class to use, either the
default XmlPortletApplicationContext or a custom context class if specified.
@param portletContext current portlet context
@return the WebApplicationContext implementation class to use
@see #CONTEXT_CLASS_PARAM
@see org.springframework.web.po... | [
"Return",
"the",
"PortletApplicationContext",
"implementation",
"class",
"to",
"use",
"either",
"the",
"default",
"XmlPortletApplicationContext",
"or",
"a",
"custom",
"context",
"class",
"if",
"specified",
"."
] | 719240fa268ddc69900ce9775d9cad3b9c543c6b | https://github.com/Jasig/spring-portlet-contrib/blob/719240fa268ddc69900ce9775d9cad3b9c543c6b/spring-webmvc-portlet-contrib/src/main/java/org/jasig/springframework/web/portlet/context/PortletContextLoader.java#L326-L347 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SystemApi.java | SystemApi.argsWithHttpInfo | public ApiResponse<GetArgsResponse> argsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = argsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetArgsResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetArgsResponse> argsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = argsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetArgsResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetArgsResponse",
">",
"argsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"argsValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
"localVarR... | Get provisioning arguments.
Returns some of provisioning variables.
@return ApiResponse<GetArgsResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"provisioning",
"arguments",
".",
"Returns",
"some",
"of",
"provisioning",
"variables",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SystemApi.java#L134-L138 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SystemApi.java | SystemApi.dynconfigGetConfigWithHttpInfo | public ApiResponse<DynconfigGetConfigResponse> dynconfigGetConfigWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = dynconfigGetConfigValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<DynconfigGetConfigResponse>(){}.getType();
return apiClient.execute(call... | java | public ApiResponse<DynconfigGetConfigResponse> dynconfigGetConfigWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = dynconfigGetConfigValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<DynconfigGetConfigResponse>(){}.getType();
return apiClient.execute(call... | [
"public",
"ApiResponse",
"<",
"DynconfigGetConfigResponse",
">",
"dynconfigGetConfigWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"dynconfigGetConfigValidateBeforeCall",
"(",
"null",
",",
"null... | Get config.json file.
Returns config.json file.
@return ApiResponse<DynconfigGetConfigResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"config",
".",
"json",
"file",
".",
"Returns",
"config",
".",
"json",
"file",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SystemApi.java#L247-L251 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/SystemApi.java | SystemApi.getConfigWithHttpInfo | public ApiResponse<GetConfigResponse> getConfigWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getConfigValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetConfigResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetConfigResponse> getConfigWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getConfigValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetConfigResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetConfigResponse",
">",
"getConfigWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getConfigValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
... | Get analytics config.
Returns exist config.
@return ApiResponse<GetConfigResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"analytics",
"config",
".",
"Returns",
"exist",
"config",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/SystemApi.java#L360-L364 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/UsersApi.java | UsersApi.deleteUser | public void deleteUser(String userDBID, Boolean keepPlaces) throws ProvisioningApiException {
try {
ApiSuccessResponse resp = usersApi.deleteUser(userDBID, keepPlaces);
if (!resp.getStatus().getCode().equals(0)) {
throw new ProvisioningApiException("Error deleting user. Code: " + resp.getStatus().getC... | java | public void deleteUser(String userDBID, Boolean keepPlaces) throws ProvisioningApiException {
try {
ApiSuccessResponse resp = usersApi.deleteUser(userDBID, keepPlaces);
if (!resp.getStatus().getCode().equals(0)) {
throw new ProvisioningApiException("Error deleting user. Code: " + resp.getStatus().getC... | [
"public",
"void",
"deleteUser",
"(",
"String",
"userDBID",
",",
"Boolean",
"keepPlaces",
")",
"throws",
"ProvisioningApiException",
"{",
"try",
"{",
"ApiSuccessResponse",
"resp",
"=",
"usersApi",
".",
"deleteUser",
"(",
"userDBID",
",",
"keepPlaces",
")",
";",
"... | Deletes a user with the given DBID.
@param userDBID The DBID of the user to be deleted. (required)
@param keepPlaces If null or false the user's places and DNs are not deleted. (optional)
@throws ProvisioningApiException if the call is unsuccessful. | [
"Deletes",
"a",
"user",
"with",
"the",
"given",
"DBID",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/UsersApi.java#L52-L62 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/UsersApi.java | UsersApi.updateUser | public void updateUser(String userDBID, User user) throws ProvisioningApiException {
try {
ApiSuccessResponse resp = usersApi.updateUser(userDBID, new UpdateUserData().data(Converters.convertUserToUpdateUserDataData(user)));
if (!resp.getStatus().getCode().equals(0)) {
throw new ProvisioningApiExcepti... | java | public void updateUser(String userDBID, User user) throws ProvisioningApiException {
try {
ApiSuccessResponse resp = usersApi.updateUser(userDBID, new UpdateUserData().data(Converters.convertUserToUpdateUserDataData(user)));
if (!resp.getStatus().getCode().equals(0)) {
throw new ProvisioningApiExcepti... | [
"public",
"void",
"updateUser",
"(",
"String",
"userDBID",
",",
"User",
"user",
")",
"throws",
"ProvisioningApiException",
"{",
"try",
"{",
"ApiSuccessResponse",
"resp",
"=",
"usersApi",
".",
"updateUser",
"(",
"userDBID",
",",
"new",
"UpdateUserData",
"(",
")",... | Updates the attributes of a user with the given DBID.
@param userDBID the DBID of the user to be updated. (required)
@param user the new attributes of the user. (required)
@throws ProvisioningApiException if the call is unsuccessful. | [
"Updates",
"the",
"attributes",
"of",
"a",
"user",
"with",
"the",
"given",
"DBID",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/UsersApi.java#L70-L80 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/ObjectsApi.java | ObjectsApi.searchDnGroups | public Results<DnGroup> searchDnGroups(SearchParams searchParams) throws ProvisioningApiException {
return searchDnGroups(
searchParams.getLimit(),
searchParams.getOffset(),
searchParams.getSearchTerm(),
searchParams.getSearchKey(),
searchParams.getMatchMethod(),
searchParams.getSortKey(),
... | java | public Results<DnGroup> searchDnGroups(SearchParams searchParams) throws ProvisioningApiException {
return searchDnGroups(
searchParams.getLimit(),
searchParams.getOffset(),
searchParams.getSearchTerm(),
searchParams.getSearchKey(),
searchParams.getMatchMethod(),
searchParams.getSortKey(),
... | [
"public",
"Results",
"<",
"DnGroup",
">",
"searchDnGroups",
"(",
"SearchParams",
"searchParams",
")",
"throws",
"ProvisioningApiException",
"{",
"return",
"searchDnGroups",
"(",
"searchParams",
".",
"getLimit",
"(",
")",
",",
"searchParams",
".",
"getOffset",
"(",
... | Get Dn groups.
Get Dn groups from Configuration Server with the specified filters.
@param searchParams object containing remaining search parameters (limit, offset, searchTerm, searchKey, matchMethod, sortKey, sortAscending, sortMethod).
@return Results object which includes list of Dn groups and total count.
@throws P... | [
"Get",
"Dn",
"groups",
".",
"Get",
"Dn",
"groups",
"from",
"Configuration",
"Server",
"with",
"the",
"specified",
"filters",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/ObjectsApi.java#L284-L295 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/EmailSettingsApi.java | EmailSettingsApi.getInboundSettingsWithHttpInfo | public ApiResponse<GetInboundResponse> getInboundSettingsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getInboundSettingsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetInboundResponse>(){}.getType();
return apiClient.execute(call, localVarReturn... | java | public ApiResponse<GetInboundResponse> getInboundSettingsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getInboundSettingsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetInboundResponse>(){}.getType();
return apiClient.execute(call, localVarReturn... | [
"public",
"ApiResponse",
"<",
"GetInboundResponse",
">",
"getInboundSettingsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getInboundSettingsValidateBeforeCall",
"(",
"null",
",",
"null",
")"... | Get inbound settings.
Returns inbound settings.
@return ApiResponse<GetInboundResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"inbound",
"settings",
".",
"Returns",
"inbound",
"settings",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/EmailSettingsApi.java#L260-L264 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/EmailSettingsApi.java | EmailSettingsApi.getOutboundSettingsWithHttpInfo | public ApiResponse<GetOutboundResponse> getOutboundSettingsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getOutboundSettingsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetOutboundResponse>(){}.getType();
return apiClient.execute(call, localVarRe... | java | public ApiResponse<GetOutboundResponse> getOutboundSettingsWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getOutboundSettingsValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetOutboundResponse>(){}.getType();
return apiClient.execute(call, localVarRe... | [
"public",
"ApiResponse",
"<",
"GetOutboundResponse",
">",
"getOutboundSettingsWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getOutboundSettingsValidateBeforeCall",
"(",
"null",
",",
"null",
... | Get outbound settings.
Returns outbound settings.
@return ApiResponse<GetOutboundResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"outbound",
"settings",
".",
"Returns",
"outbound",
"settings",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/EmailSettingsApi.java#L373-L377 | train |
ralscha/bsoncodec-apt | src/main/java/ch/rasc/bsoncodec/CodecCodeGenerator.java | CodecCodeGenerator.lookupId | private static Element lookupId(List<Element> fields) {
Element objectIdField = null;
Element uuidField = null;
Element _idField = null;
Element idField = null;
for (Element field : fields) {
if (field.getAnnotation(Id.class) != null) {
return field;
}
if (isObjectId(field)) {
objectIdField =... | java | private static Element lookupId(List<Element> fields) {
Element objectIdField = null;
Element uuidField = null;
Element _idField = null;
Element idField = null;
for (Element field : fields) {
if (field.getAnnotation(Id.class) != null) {
return field;
}
if (isObjectId(field)) {
objectIdField =... | [
"private",
"static",
"Element",
"lookupId",
"(",
"List",
"<",
"Element",
">",
"fields",
")",
"{",
"Element",
"objectIdField",
"=",
"null",
";",
"Element",
"uuidField",
"=",
"null",
";",
"Element",
"_idField",
"=",
"null",
";",
"Element",
"idField",
"=",
"n... | Find a field with the @Id annotation OR with type ObjectId OR with type UUID OR
with name _id OR with name id | [
"Find",
"a",
"field",
"with",
"the"
] | 999d87ec1ece9848f75954c9d9a0c4a005575d2f | https://github.com/ralscha/bsoncodec-apt/blob/999d87ec1ece9848f75954c9d9a0c4a005575d2f/src/main/java/ch/rasc/bsoncodec/CodecCodeGenerator.java#L727-L764 | train |
venkatramanm/swf-all | swf/src/main/java/com/venky/swf/path/Path.java | Path.getUser | public User getUser(String fieldName, String fieldValue){
Select q = new Select().from(User.class);
String nameColumn = ModelReflector.instance(User.class).getColumnDescriptor(fieldName).getName();
q.where(new Expression(q.getPool(),nameColumn,Operator.EQ,new BindVariable(q.getPool(),fieldValue)... | java | public User getUser(String fieldName, String fieldValue){
Select q = new Select().from(User.class);
String nameColumn = ModelReflector.instance(User.class).getColumnDescriptor(fieldName).getName();
q.where(new Expression(q.getPool(),nameColumn,Operator.EQ,new BindVariable(q.getPool(),fieldValue)... | [
"public",
"User",
"getUser",
"(",
"String",
"fieldName",
",",
"String",
"fieldValue",
")",
"{",
"Select",
"q",
"=",
"new",
"Select",
"(",
")",
".",
"from",
"(",
"User",
".",
"class",
")",
";",
"String",
"nameColumn",
"=",
"ModelReflector",
".",
"instance... | Can be cast to any user model class as the proxy implements all the user classes. | [
"Can",
"be",
"cast",
"to",
"any",
"user",
"model",
"class",
"as",
"the",
"proxy",
"implements",
"all",
"the",
"user",
"classes",
"."
] | e6ca342df0645bf1122d81e302575014ad565b69 | https://github.com/venkatramanm/swf-all/blob/e6ca342df0645bf1122d81e302575014ad565b69/swf/src/main/java/com/venky/swf/path/Path.java#L677-L687 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/TraceInterceptor.java | TraceInterceptor.intercept | @Override
public Response intercept(Chain chain) throws IOException {
Request request = chain.request();
request = request.newBuilder()
.addHeader(TRACEID_HEADER, makeUniqueId())
.addHeader(SPANID_HEADER, makeUniqueId()).build();
return chain.p... | java | @Override
public Response intercept(Chain chain) throws IOException {
Request request = chain.request();
request = request.newBuilder()
.addHeader(TRACEID_HEADER, makeUniqueId())
.addHeader(SPANID_HEADER, makeUniqueId()).build();
return chain.p... | [
"@",
"Override",
"public",
"Response",
"intercept",
"(",
"Chain",
"chain",
")",
"throws",
"IOException",
"{",
"Request",
"request",
"=",
"chain",
".",
"request",
"(",
")",
";",
"request",
"=",
"request",
".",
"newBuilder",
"(",
")",
".",
"addHeader",
"(",
... | 64-bit ids | [
"64",
"-",
"bit",
"ids"
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/TraceInterceptor.java#L21-L29 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/internal/provisioning/api/AuditApi.java | AuditApi.getAuditWithHttpInfo | public ApiResponse<GetAuditResponse> getAuditWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getAuditValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetAuditResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | java | public ApiResponse<GetAuditResponse> getAuditWithHttpInfo() throws ApiException {
com.squareup.okhttp.Call call = getAuditValidateBeforeCall(null, null);
Type localVarReturnType = new TypeToken<GetAuditResponse>(){}.getType();
return apiClient.execute(call, localVarReturnType);
} | [
"public",
"ApiResponse",
"<",
"GetAuditResponse",
">",
"getAuditWithHttpInfo",
"(",
")",
"throws",
"ApiException",
"{",
"com",
".",
"squareup",
".",
"okhttp",
".",
"Call",
"call",
"=",
"getAuditValidateBeforeCall",
"(",
"null",
",",
"null",
")",
";",
"Type",
"... | Get audit records.
Returns audit records.
@return ApiResponse<GetAuditResponse>
@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body | [
"Get",
"audit",
"records",
".",
"Returns",
"audit",
"records",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/internal/provisioning/api/AuditApi.java#L132-L136 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/OptionsApi.java | OptionsApi.getOptions | public Options getOptions(String personDBID, String agentGroupDBID) throws ProvisioningApiException {
try {
OptionsGetResponseSuccess resp = optionsApi.optionsGet(
personDBID,
agentGroupDBID
);
if (!resp.getStatus().getCode().eq... | java | public Options getOptions(String personDBID, String agentGroupDBID) throws ProvisioningApiException {
try {
OptionsGetResponseSuccess resp = optionsApi.optionsGet(
personDBID,
agentGroupDBID
);
if (!resp.getStatus().getCode().eq... | [
"public",
"Options",
"getOptions",
"(",
"String",
"personDBID",
",",
"String",
"agentGroupDBID",
")",
"throws",
"ProvisioningApiException",
"{",
"try",
"{",
"OptionsGetResponseSuccess",
"resp",
"=",
"optionsApi",
".",
"optionsGet",
"(",
"personDBID",
",",
"agentGroupD... | Get options.
Get options for a specified application and merge them with the person and agent group annexes.
@param personDBID The DBID of a person. Options are merged with the person's annex and the annexes of the person's agent groups. Mutual with agent_group_dbid. (optional)
@param agentGroupDBID The D... | [
"Get",
"options",
".",
"Get",
"options",
"for",
"a",
"specified",
"application",
"and",
"merge",
"them",
"with",
"the",
"person",
"and",
"agent",
"group",
"annexes",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/OptionsApi.java#L31-L52 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/OptionsApi.java | OptionsApi.modifyOptions | public void modifyOptions(Map<String, Object> options) throws ProvisioningApiException {
try {
OptionsPostResponseStatusSuccess resp = optionsApi.optionsPost(new OptionsPost().data(new OptionsPostData().options(options)));
if (!resp.getStatus().getCode().equals(0)) {
... | java | public void modifyOptions(Map<String, Object> options) throws ProvisioningApiException {
try {
OptionsPostResponseStatusSuccess resp = optionsApi.optionsPost(new OptionsPost().data(new OptionsPostData().options(options)));
if (!resp.getStatus().getCode().equals(0)) {
... | [
"public",
"void",
"modifyOptions",
"(",
"Map",
"<",
"String",
",",
"Object",
">",
"options",
")",
"throws",
"ProvisioningApiException",
"{",
"try",
"{",
"OptionsPostResponseStatusSuccess",
"resp",
"=",
"optionsApi",
".",
"optionsPost",
"(",
"new",
"OptionsPost",
"... | Modify options.
Replace the existing application options with the specified new values.
@param options attributes to be updated.
@throws ProvisioningApiException if the call is unsuccessful. | [
"Modify",
"options",
".",
"Replace",
"the",
"existing",
"application",
"options",
"with",
"the",
"specified",
"new",
"values",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/OptionsApi.java#L61-L73 | train |
GenesysPureEngage/provisioning-client-java | src/main/java/com/genesys/provisioning/OptionsApi.java | OptionsApi.updateOptions | public void updateOptions(Map<String, Object> newOptions, Map<String, Object> changedOptions, Map<String, Object> deletedOptions) throws ProvisioningApiException {
try {
OptionsPutResponseStatusSuccess resp = optionsApi.optionsPut(
new OptionsPut()
... | java | public void updateOptions(Map<String, Object> newOptions, Map<String, Object> changedOptions, Map<String, Object> deletedOptions) throws ProvisioningApiException {
try {
OptionsPutResponseStatusSuccess resp = optionsApi.optionsPut(
new OptionsPut()
... | [
"public",
"void",
"updateOptions",
"(",
"Map",
"<",
"String",
",",
"Object",
">",
"newOptions",
",",
"Map",
"<",
"String",
",",
"Object",
">",
"changedOptions",
",",
"Map",
"<",
"String",
",",
"Object",
">",
"deletedOptions",
")",
"throws",
"ProvisioningApiE... | Add, edit or delete options values.
Add, edit or delete option values for the specified application.
@param newOptions options to add.
@param changedOptions options to change.
@param deletedOptions options to remove.
@throws ProvisioningApiException if the call is unsuccessful. | [
"Add",
"edit",
"or",
"delete",
"options",
"values",
".",
"Add",
"edit",
"or",
"delete",
"option",
"values",
"for",
"the",
"specified",
"application",
"."
] | 1ad594c3767cec83052168e350994f922a26f75e | https://github.com/GenesysPureEngage/provisioning-client-java/blob/1ad594c3767cec83052168e350994f922a26f75e/src/main/java/com/genesys/provisioning/OptionsApi.java#L84-L104 | train |
jayantk/jklol | src/com/jayantkrish/jklol/lisp/AmbEval.java | AmbEval.doDefine | private final EvalResult doDefine(List<SExpression> subexpressions, Environment environment,
ParametricBfgBuilder builder, EvalContext context) {
int nameToBind = subexpressions.get(1).getConstantIndex();
if (subexpressions.size() == 3) {
// (define name value-expression)
// Binds a name to th... | java | private final EvalResult doDefine(List<SExpression> subexpressions, Environment environment,
ParametricBfgBuilder builder, EvalContext context) {
int nameToBind = subexpressions.get(1).getConstantIndex();
if (subexpressions.size() == 3) {
// (define name value-expression)
// Binds a name to th... | [
"private",
"final",
"EvalResult",
"doDefine",
"(",
"List",
"<",
"SExpression",
">",
"subexpressions",
",",
"Environment",
"environment",
",",
"ParametricBfgBuilder",
"builder",
",",
"EvalContext",
"context",
")",
"{",
"int",
"nameToBind",
"=",
"subexpressions",
".",... | Evaluates the "define" special form.
@param subexpressions
@param environment
@param builder
@return | [
"Evaluates",
"the",
"define",
"special",
"form",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/lisp/AmbEval.java#L222-L238 | train |
davidcarboni/cryptolite-java | src/main/java/com/github/davidcarboni/cryptolite/Generate.java | Generate.password | public static String password(int length) {
StringBuilder result = new StringBuilder();
byte[] values = byteArray(length);
// We use a modulus of an increasing index rather than of the byte values
// to avoid certain characters coming up more often.
int index = 0;
for (... | java | public static String password(int length) {
StringBuilder result = new StringBuilder();
byte[] values = byteArray(length);
// We use a modulus of an increasing index rather than of the byte values
// to avoid certain characters coming up more often.
int index = 0;
for (... | [
"public",
"static",
"String",
"password",
"(",
"int",
"length",
")",
"{",
"StringBuilder",
"result",
"=",
"new",
"StringBuilder",
"(",
")",
";",
"byte",
"[",
"]",
"values",
"=",
"byteArray",
"(",
"length",
")",
";",
"// We use a modulus of an increasing index ra... | Generates a random password.
@param length The length of the password to be returned.
@return A password of the specified length, selected from {@link #passwordCharacters}. | [
"Generates",
"a",
"random",
"password",
"."
] | e67954181a04ffc9beb1d9abca1421195fcf9764 | https://github.com/davidcarboni/cryptolite-java/blob/e67954181a04ffc9beb1d9abca1421195fcf9764/src/main/java/com/github/davidcarboni/cryptolite/Generate.java#L91-L106 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getSyntacticParse | public CcgSyntaxTree getSyntacticParse() {
HeadedSyntacticCategory originalSyntax = null;
if (unaryRule != null) {
originalSyntax = unaryRule.getUnaryRule().getInputSyntacticCategory().getCanonicalForm();
} else {
originalSyntax = syntax;
}
if (isTerminal()) {
return CcgSyntaxTree... | java | public CcgSyntaxTree getSyntacticParse() {
HeadedSyntacticCategory originalSyntax = null;
if (unaryRule != null) {
originalSyntax = unaryRule.getUnaryRule().getInputSyntacticCategory().getCanonicalForm();
} else {
originalSyntax = syntax;
}
if (isTerminal()) {
return CcgSyntaxTree... | [
"public",
"CcgSyntaxTree",
"getSyntacticParse",
"(",
")",
"{",
"HeadedSyntacticCategory",
"originalSyntax",
"=",
"null",
";",
"if",
"(",
"unaryRule",
"!=",
"null",
")",
"{",
"originalSyntax",
"=",
"unaryRule",
".",
"getUnaryRule",
"(",
")",
".",
"getInputSyntactic... | Gets a representation of the syntactic structure of this parse,
omitting all semantic information.
@return | [
"Gets",
"a",
"representation",
"of",
"the",
"syntactic",
"structure",
"of",
"this",
"parse",
"omitting",
"all",
"semantic",
"information",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L197-L215 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getLogicalForm | public Expression2 getLogicalForm() {
Expression2 preUnaryLogicalForm = getPreUnaryLogicalForm();
if (unaryRule == null) {
return preUnaryLogicalForm;
} else if (preUnaryLogicalForm == null || unaryRule.getUnaryRule().getLogicalForm() == null) {
return null;
} else {
return Expression2... | java | public Expression2 getLogicalForm() {
Expression2 preUnaryLogicalForm = getPreUnaryLogicalForm();
if (unaryRule == null) {
return preUnaryLogicalForm;
} else if (preUnaryLogicalForm == null || unaryRule.getUnaryRule().getLogicalForm() == null) {
return null;
} else {
return Expression2... | [
"public",
"Expression2",
"getLogicalForm",
"(",
")",
"{",
"Expression2",
"preUnaryLogicalForm",
"=",
"getPreUnaryLogicalForm",
"(",
")",
";",
"if",
"(",
"unaryRule",
"==",
"null",
")",
"{",
"return",
"preUnaryLogicalForm",
";",
"}",
"else",
"if",
"(",
"preUnaryL... | Gets the logical form for this CCG parse.
@return | [
"Gets",
"the",
"logical",
"form",
"for",
"this",
"CCG",
"parse",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L222-L231 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getLogicalFormForSpan | public SpannedExpression getLogicalFormForSpan(int spanStart, int spanEnd) {
CcgParse spanningParse = getParseForSpan(spanStart, spanEnd);
Expression2 lf = spanningParse.getPreUnaryLogicalForm();
if (lf != null) {
return new SpannedExpression(spanningParse.getHeadedSyntacticCategory(),
spann... | java | public SpannedExpression getLogicalFormForSpan(int spanStart, int spanEnd) {
CcgParse spanningParse = getParseForSpan(spanStart, spanEnd);
Expression2 lf = spanningParse.getPreUnaryLogicalForm();
if (lf != null) {
return new SpannedExpression(spanningParse.getHeadedSyntacticCategory(),
spann... | [
"public",
"SpannedExpression",
"getLogicalFormForSpan",
"(",
"int",
"spanStart",
",",
"int",
"spanEnd",
")",
"{",
"CcgParse",
"spanningParse",
"=",
"getParseForSpan",
"(",
"spanStart",
",",
"spanEnd",
")",
";",
"Expression2",
"lf",
"=",
"spanningParse",
".",
"getP... | Returns the logical form for the smallest subtree of the parse which
completely contains the given span.
@param spanStart
@param spanEnd
@return | [
"Returns",
"the",
"logical",
"form",
"for",
"the",
"smallest",
"subtree",
"of",
"the",
"parse",
"which",
"completely",
"contains",
"the",
"given",
"span",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L241-L250 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getSpannedLogicalForms | public List<SpannedExpression> getSpannedLogicalForms() {
List<SpannedExpression> spannedExpressions = Lists.newArrayList();
getSpannedLogicalFormsHelper(spannedExpressions);
return spannedExpressions;
} | java | public List<SpannedExpression> getSpannedLogicalForms() {
List<SpannedExpression> spannedExpressions = Lists.newArrayList();
getSpannedLogicalFormsHelper(spannedExpressions);
return spannedExpressions;
} | [
"public",
"List",
"<",
"SpannedExpression",
">",
"getSpannedLogicalForms",
"(",
")",
"{",
"List",
"<",
"SpannedExpression",
">",
"spannedExpressions",
"=",
"Lists",
".",
"newArrayList",
"(",
")",
";",
"getSpannedLogicalFormsHelper",
"(",
"spannedExpressions",
")",
"... | Gets the logical forms for every subspan of this parse tree.
Many of the returned logical forms combine with each other
during the parse of the sentence.
@return | [
"Gets",
"the",
"logical",
"forms",
"for",
"every",
"subspan",
"of",
"this",
"parse",
"tree",
".",
"Many",
"of",
"the",
"returned",
"logical",
"forms",
"combine",
"with",
"each",
"other",
"during",
"the",
"parse",
"of",
"the",
"sentence",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L259-L263 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getSpannedWords | public List<String> getSpannedWords() {
if (isTerminal()) {
return words;
} else {
List<String> words = Lists.newArrayList();
words.addAll(left.getSpannedWords());
words.addAll(right.getSpannedWords());
return words;
}
} | java | public List<String> getSpannedWords() {
if (isTerminal()) {
return words;
} else {
List<String> words = Lists.newArrayList();
words.addAll(left.getSpannedWords());
words.addAll(right.getSpannedWords());
return words;
}
} | [
"public",
"List",
"<",
"String",
">",
"getSpannedWords",
"(",
")",
"{",
"if",
"(",
"isTerminal",
"(",
")",
")",
"{",
"return",
"words",
";",
"}",
"else",
"{",
"List",
"<",
"String",
">",
"words",
"=",
"Lists",
".",
"newArrayList",
"(",
")",
";",
"w... | Gets all of the words spanned by this node of the parse tree,
in sentence order.
@return | [
"Gets",
"all",
"of",
"the",
"words",
"spanned",
"by",
"this",
"node",
"of",
"the",
"parse",
"tree",
"in",
"sentence",
"order",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L386-L395 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getSpannedPosTags | public List<String> getSpannedPosTags() {
if (isTerminal()) {
return posTags;
} else {
List<String> tags = Lists.newArrayList();
tags.addAll(left.getSpannedPosTags());
tags.addAll(right.getSpannedPosTags());
return tags;
}
} | java | public List<String> getSpannedPosTags() {
if (isTerminal()) {
return posTags;
} else {
List<String> tags = Lists.newArrayList();
tags.addAll(left.getSpannedPosTags());
tags.addAll(right.getSpannedPosTags());
return tags;
}
} | [
"public",
"List",
"<",
"String",
">",
"getSpannedPosTags",
"(",
")",
"{",
"if",
"(",
"isTerminal",
"(",
")",
")",
"{",
"return",
"posTags",
";",
"}",
"else",
"{",
"List",
"<",
"String",
">",
"tags",
"=",
"Lists",
".",
"newArrayList",
"(",
")",
";",
... | Gets all of the part-of-speech tags spanned by this node of
the parse tree, in sentence order.
@return | [
"Gets",
"all",
"of",
"the",
"part",
"-",
"of",
"-",
"speech",
"tags",
"spanned",
"by",
"this",
"node",
"of",
"the",
"parse",
"tree",
"in",
"sentence",
"order",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L403-L412 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getSpannedLexiconEntries | public List<LexiconEntryInfo> getSpannedLexiconEntries() {
if (isTerminal()) {
return Arrays.asList(lexiconEntry);
} else {
List<LexiconEntryInfo> lexiconEntries = Lists.newArrayList();
lexiconEntries.addAll(left.getSpannedLexiconEntries());
lexiconEntries.addAll(right.getSpannedLexiconE... | java | public List<LexiconEntryInfo> getSpannedLexiconEntries() {
if (isTerminal()) {
return Arrays.asList(lexiconEntry);
} else {
List<LexiconEntryInfo> lexiconEntries = Lists.newArrayList();
lexiconEntries.addAll(left.getSpannedLexiconEntries());
lexiconEntries.addAll(right.getSpannedLexiconE... | [
"public",
"List",
"<",
"LexiconEntryInfo",
">",
"getSpannedLexiconEntries",
"(",
")",
"{",
"if",
"(",
"isTerminal",
"(",
")",
")",
"{",
"return",
"Arrays",
".",
"asList",
"(",
"lexiconEntry",
")",
";",
"}",
"else",
"{",
"List",
"<",
"LexiconEntryInfo",
">"... | Gets the lexicon entries for all terminal children of this
parse tree node, in left-to-right order.
@return | [
"Gets",
"the",
"lexicon",
"entries",
"for",
"all",
"terminal",
"children",
"of",
"this",
"parse",
"tree",
"node",
"in",
"left",
"-",
"to",
"-",
"right",
"order",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L420-L429 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getAllDependencies | public List<DependencyStructure> getAllDependencies() {
List<DependencyStructure> deps = Lists.newArrayList();
if (!isTerminal()) {
deps.addAll(left.getAllDependencies());
deps.addAll(right.getAllDependencies());
}
deps.addAll(dependencies);
return deps;
} | java | public List<DependencyStructure> getAllDependencies() {
List<DependencyStructure> deps = Lists.newArrayList();
if (!isTerminal()) {
deps.addAll(left.getAllDependencies());
deps.addAll(right.getAllDependencies());
}
deps.addAll(dependencies);
return deps;
} | [
"public",
"List",
"<",
"DependencyStructure",
">",
"getAllDependencies",
"(",
")",
"{",
"List",
"<",
"DependencyStructure",
">",
"deps",
"=",
"Lists",
".",
"newArrayList",
"(",
")",
";",
"if",
"(",
"!",
"isTerminal",
"(",
")",
")",
"{",
"deps",
".",
"add... | Gets all dependency structures populated during parsing.
@return | [
"Gets",
"all",
"dependency",
"structures",
"populated",
"during",
"parsing",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L538-L546 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/CcgParse.java | CcgParse.getAllDependenciesIndexedByHeadWordIndex | public Multimap<Integer, DependencyStructure> getAllDependenciesIndexedByHeadWordIndex() {
Multimap<Integer, DependencyStructure> map = HashMultimap.create();
for (DependencyStructure dep : getAllDependencies()) {
map.put(dep.getHeadWordIndex(), dep);
}
return map;
} | java | public Multimap<Integer, DependencyStructure> getAllDependenciesIndexedByHeadWordIndex() {
Multimap<Integer, DependencyStructure> map = HashMultimap.create();
for (DependencyStructure dep : getAllDependencies()) {
map.put(dep.getHeadWordIndex(), dep);
}
return map;
} | [
"public",
"Multimap",
"<",
"Integer",
",",
"DependencyStructure",
">",
"getAllDependenciesIndexedByHeadWordIndex",
"(",
")",
"{",
"Multimap",
"<",
"Integer",
",",
"DependencyStructure",
">",
"map",
"=",
"HashMultimap",
".",
"create",
"(",
")",
";",
"for",
"(",
"... | Gets all dependency structures populated during parsing, indexed
by the word that projects the dependency.
@return | [
"Gets",
"all",
"dependency",
"structures",
"populated",
"during",
"parsing",
"indexed",
"by",
"the",
"word",
"that",
"projects",
"the",
"dependency",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/CcgParse.java#L554-L560 | train |
cpollet/jixture | core/src/main/java/net/cpollet/jixture/fixtures/SqlFileFixture.java | SqlFileFixture.load | @Override
public void load(UnitDaoFactory unitDaoFactory) {
BufferedReader reader = new BufferedReader(new InputStreamReader(fileInputStream));
BufferedReaderIterator iterator = new BufferedReaderIterator(reader);
StringBuilder currentQuery = new StringBuilder();
while (iterator.hasNext()) {
String line = ... | java | @Override
public void load(UnitDaoFactory unitDaoFactory) {
BufferedReader reader = new BufferedReader(new InputStreamReader(fileInputStream));
BufferedReaderIterator iterator = new BufferedReaderIterator(reader);
StringBuilder currentQuery = new StringBuilder();
while (iterator.hasNext()) {
String line = ... | [
"@",
"Override",
"public",
"void",
"load",
"(",
"UnitDaoFactory",
"unitDaoFactory",
")",
"{",
"BufferedReader",
"reader",
"=",
"new",
"BufferedReader",
"(",
"new",
"InputStreamReader",
"(",
"fileInputStream",
")",
")",
";",
"BufferedReaderIterator",
"iterator",
"=",... | Execute the SQL file's content.
@param unitDaoFactory the {@link net.cpollet.jixture.dao.UnitDaoFactory} to use. | [
"Execute",
"the",
"SQL",
"file",
"s",
"content",
"."
] | faef0d4991f81c2cdb5be3ba24176636ef0cc433 | https://github.com/cpollet/jixture/blob/faef0d4991f81c2cdb5be3ba24176636ef0cc433/core/src/main/java/net/cpollet/jixture/fixtures/SqlFileFixture.java#L63-L81 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/lexinduct/vote/VotingLexiconInduction.java | VotingLexiconInduction.createParser | private static ParserInfo createParser(LexiconInductionCcgParserFactory factory,
SufficientStatistics currentParameters, Collection<LexiconEntry> currentLexicon) {
ParametricCcgParser family = factory.getParametricCcgParser(currentLexicon);
SufficientStatistics newParameters = family.getNewSufficientStati... | java | private static ParserInfo createParser(LexiconInductionCcgParserFactory factory,
SufficientStatistics currentParameters, Collection<LexiconEntry> currentLexicon) {
ParametricCcgParser family = factory.getParametricCcgParser(currentLexicon);
SufficientStatistics newParameters = family.getNewSufficientStati... | [
"private",
"static",
"ParserInfo",
"createParser",
"(",
"LexiconInductionCcgParserFactory",
"factory",
",",
"SufficientStatistics",
"currentParameters",
",",
"Collection",
"<",
"LexiconEntry",
">",
"currentLexicon",
")",
"{",
"ParametricCcgParser",
"family",
"=",
"factory",... | Creates a CCG parser given parameters and a lexicon.
@param factory
@param currentParameters
@param currentLexicon
@return | [
"Creates",
"a",
"CCG",
"parser",
"given",
"parameters",
"and",
"a",
"lexicon",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/lexinduct/vote/VotingLexiconInduction.java#L179-L189 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/lexinduct/vote/VotingLexiconInduction.java | VotingLexiconInduction.getPartitionFunction | private double getPartitionFunction(List<CcgParse> parses) {
double partitionFunction = 0.0;
for (CcgParse parse : parses) {
partitionFunction += parse.getSubtreeProbability();
}
return partitionFunction;
} | java | private double getPartitionFunction(List<CcgParse> parses) {
double partitionFunction = 0.0;
for (CcgParse parse : parses) {
partitionFunction += parse.getSubtreeProbability();
}
return partitionFunction;
} | [
"private",
"double",
"getPartitionFunction",
"(",
"List",
"<",
"CcgParse",
">",
"parses",
")",
"{",
"double",
"partitionFunction",
"=",
"0.0",
";",
"for",
"(",
"CcgParse",
"parse",
":",
"parses",
")",
"{",
"partitionFunction",
"+=",
"parse",
".",
"getSubtreePr... | Gets the sum total probability assigned to all parses.
@param parses
@return | [
"Gets",
"the",
"sum",
"total",
"probability",
"assigned",
"to",
"all",
"parses",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/lexinduct/vote/VotingLexiconInduction.java#L238-L244 | train |
jayantk/jklol | src/com/jayantkrish/jklol/sequence/SequenceModelUtils.java | SequenceModelUtils.buildSequenceModel | public static ParametricFactorGraph buildSequenceModel(Iterable<String> emissionFeatureLines,
String featureDelimiter) {
// Read in the possible values of each variable.
List<String> words = StringUtils.readColumnFromDelimitedLines(emissionFeatureLines, 0, featureDelimiter);
List<String> labels = Stri... | java | public static ParametricFactorGraph buildSequenceModel(Iterable<String> emissionFeatureLines,
String featureDelimiter) {
// Read in the possible values of each variable.
List<String> words = StringUtils.readColumnFromDelimitedLines(emissionFeatureLines, 0, featureDelimiter);
List<String> labels = Stri... | [
"public",
"static",
"ParametricFactorGraph",
"buildSequenceModel",
"(",
"Iterable",
"<",
"String",
">",
"emissionFeatureLines",
",",
"String",
"featureDelimiter",
")",
"{",
"// Read in the possible values of each variable.",
"List",
"<",
"String",
">",
"words",
"=",
"Stri... | Constructs a sequence model from the lines of a file containing features of
the emission distribution.
@param emissionFeatureLines
@param featureDelimiter
@return | [
"Constructs",
"a",
"sequence",
"model",
"from",
"the",
"lines",
"of",
"a",
"file",
"containing",
"features",
"of",
"the",
"emission",
"distribution",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/sequence/SequenceModelUtils.java#L40-L86 | train |
jayantk/jklol | src/com/jayantkrish/jklol/models/AbstractFactorGraphBuilder.java | AbstractFactorGraphBuilder.addConstantFactor | public void addConstantFactor(String factorName, PlateFactor factor) {
constantFactors.add(factor);
constantFactorNames.add(factorName);
} | java | public void addConstantFactor(String factorName, PlateFactor factor) {
constantFactors.add(factor);
constantFactorNames.add(factorName);
} | [
"public",
"void",
"addConstantFactor",
"(",
"String",
"factorName",
",",
"PlateFactor",
"factor",
")",
"{",
"constantFactors",
".",
"add",
"(",
"factor",
")",
";",
"constantFactorNames",
".",
"add",
"(",
"factorName",
")",
";",
"}"
] | Adds an unparameterized, dynamically-instantiated factor to the
model under construction.
@param factor | [
"Adds",
"an",
"unparameterized",
"dynamically",
"-",
"instantiated",
"factor",
"to",
"the",
"model",
"under",
"construction",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/models/AbstractFactorGraphBuilder.java#L95-L98 | train |
jayantk/jklol | src/com/jayantkrish/jklol/models/AbstractFactorGraphBuilder.java | AbstractFactorGraphBuilder.addFactor | public void addFactor(String factorName, T factor, VariablePattern factorPattern) {
parametricFactors.add(factor);
factorPatterns.add(factorPattern);
parametricFactorNames.add(factorName);
} | java | public void addFactor(String factorName, T factor, VariablePattern factorPattern) {
parametricFactors.add(factor);
factorPatterns.add(factorPattern);
parametricFactorNames.add(factorName);
} | [
"public",
"void",
"addFactor",
"(",
"String",
"factorName",
",",
"T",
"factor",
",",
"VariablePattern",
"factorPattern",
")",
"{",
"parametricFactors",
".",
"add",
"(",
"factor",
")",
";",
"factorPatterns",
".",
"add",
"(",
"factorPattern",
")",
";",
"parametr... | Adds a parameterized factor to the log linear model being
constructed.
@param factor | [
"Adds",
"a",
"parameterized",
"factor",
"to",
"the",
"log",
"linear",
"model",
"being",
"constructed",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/models/AbstractFactorGraphBuilder.java#L106-L110 | train |
cpollet/jixture | core/src/main/java/net/cpollet/jixture/fixtures/SqlFixture.java | SqlFixture.load | @Override
public void load(UnitDaoFactory unitDaoFactory) {
for (String query : queries) {
unitDaoFactory.getUnitDao().execute(query);
}
} | java | @Override
public void load(UnitDaoFactory unitDaoFactory) {
for (String query : queries) {
unitDaoFactory.getUnitDao().execute(query);
}
} | [
"@",
"Override",
"public",
"void",
"load",
"(",
"UnitDaoFactory",
"unitDaoFactory",
")",
"{",
"for",
"(",
"String",
"query",
":",
"queries",
")",
"{",
"unitDaoFactory",
".",
"getUnitDao",
"(",
")",
".",
"execute",
"(",
"query",
")",
";",
"}",
"}"
] | Execute the SQL queries.
@param unitDaoFactory the {@link net.cpollet.jixture.dao.UnitDaoFactory} to use. | [
"Execute",
"the",
"SQL",
"queries",
"."
] | faef0d4991f81c2cdb5be3ba24176636ef0cc433 | https://github.com/cpollet/jixture/blob/faef0d4991f81c2cdb5be3ba24176636ef0cc433/core/src/main/java/net/cpollet/jixture/fixtures/SqlFixture.java#L65-L70 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/chart/CcgExactChart.java | CcgExactChart.longMultisetsEqual | private static final boolean longMultisetsEqual(long[] firstDeps, long[] secondDeps) {
if (firstDeps.length != secondDeps.length) {
return false;
}
Arrays.sort(firstDeps);
Arrays.sort(secondDeps);
for (int i = 0; i < firstDeps.length; i++) {
if (firstDeps[i] != secondDeps[i]) {
... | java | private static final boolean longMultisetsEqual(long[] firstDeps, long[] secondDeps) {
if (firstDeps.length != secondDeps.length) {
return false;
}
Arrays.sort(firstDeps);
Arrays.sort(secondDeps);
for (int i = 0; i < firstDeps.length; i++) {
if (firstDeps[i] != secondDeps[i]) {
... | [
"private",
"static",
"final",
"boolean",
"longMultisetsEqual",
"(",
"long",
"[",
"]",
"firstDeps",
",",
"long",
"[",
"]",
"secondDeps",
")",
"{",
"if",
"(",
"firstDeps",
".",
"length",
"!=",
"secondDeps",
".",
"length",
")",
"{",
"return",
"false",
";",
... | Checks if two multisets of long numbers contain the same keys
with the same frequency
@param first
@param second
@return | [
"Checks",
"if",
"two",
"multisets",
"of",
"long",
"numbers",
"contain",
"the",
"same",
"keys",
"with",
"the",
"same",
"frequency"
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/chart/CcgExactChart.java#L171-L184 | train |
jayantk/jklol | src/com/jayantkrish/jklol/util/IndexedList.java | IndexedList.add | public int add(T item) {
if (itemIndex.containsKey(item)) {
// Items can only be added once
return itemIndex.get(item);
}
int index = items.size();
itemIndex.put(item, index);
items.add(item);
return index;
} | java | public int add(T item) {
if (itemIndex.containsKey(item)) {
// Items can only be added once
return itemIndex.get(item);
}
int index = items.size();
itemIndex.put(item, index);
items.add(item);
return index;
} | [
"public",
"int",
"add",
"(",
"T",
"item",
")",
"{",
"if",
"(",
"itemIndex",
".",
"containsKey",
"(",
"item",
")",
")",
"{",
"// Items can only be added once",
"return",
"itemIndex",
".",
"get",
"(",
"item",
")",
";",
"}",
"int",
"index",
"=",
"items",
... | Add a new element to this set. Note that there can only be a single
copy of any given item in the list. Returns the index of the added item. | [
"Add",
"a",
"new",
"element",
"to",
"this",
"set",
".",
"Note",
"that",
"there",
"can",
"only",
"be",
"a",
"single",
"copy",
"of",
"any",
"given",
"item",
"in",
"the",
"list",
".",
"Returns",
"the",
"index",
"of",
"the",
"added",
"item",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/util/IndexedList.java#L64-L73 | train |
jayantk/jklol | src/com/jayantkrish/jklol/util/IndexedList.java | IndexedList.getIndex | public int getIndex(Object item) {
if (!itemIndex.containsKey(item)) {
throw new NoSuchElementException("No such item: " + item);
}
return itemIndex.get(item);
} | java | public int getIndex(Object item) {
if (!itemIndex.containsKey(item)) {
throw new NoSuchElementException("No such item: " + item);
}
return itemIndex.get(item);
} | [
"public",
"int",
"getIndex",
"(",
"Object",
"item",
")",
"{",
"if",
"(",
"!",
"itemIndex",
".",
"containsKey",
"(",
"item",
")",
")",
"{",
"throw",
"new",
"NoSuchElementException",
"(",
"\"No such item: \"",
"+",
"item",
")",
";",
"}",
"return",
"itemIndex... | Get the index in the list of the specified item. | [
"Get",
"the",
"index",
"in",
"the",
"list",
"of",
"the",
"specified",
"item",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/util/IndexedList.java#L101-L106 | train |
jayantk/jklol | src/com/jayantkrish/jklol/util/IndexedList.java | IndexedList.get | public T get(int index) {
if (index >= items.size() || index < 0) {
throw new IndexOutOfBoundsException("size: " + items.size() + " index: " + index);
}
return items.get(index);
} | java | public T get(int index) {
if (index >= items.size() || index < 0) {
throw new IndexOutOfBoundsException("size: " + items.size() + " index: " + index);
}
return items.get(index);
} | [
"public",
"T",
"get",
"(",
"int",
"index",
")",
"{",
"if",
"(",
"index",
">=",
"items",
".",
"size",
"(",
")",
"||",
"index",
"<",
"0",
")",
"{",
"throw",
"new",
"IndexOutOfBoundsException",
"(",
"\"size: \"",
"+",
"items",
".",
"size",
"(",
")",
"... | Get the item with the specified index. | [
"Get",
"the",
"item",
"with",
"the",
"specified",
"index",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/util/IndexedList.java#L111-L116 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/lambda2/Expression2.java | Expression2.getParentExpressionIndex | public int getParentExpressionIndex(int index) {
if (index == 0) {
return -1;
} else {
int[] parts = findSubexpression(index);
int parentIndex = subexpressions.get(parts[0]).getParentExpressionIndex(parts[1]);
if (parentIndex == -1) {
// index refers to a child of this exp... | java | public int getParentExpressionIndex(int index) {
if (index == 0) {
return -1;
} else {
int[] parts = findSubexpression(index);
int parentIndex = subexpressions.get(parts[0]).getParentExpressionIndex(parts[1]);
if (parentIndex == -1) {
// index refers to a child of this exp... | [
"public",
"int",
"getParentExpressionIndex",
"(",
"int",
"index",
")",
"{",
"if",
"(",
"index",
"==",
"0",
")",
"{",
"return",
"-",
"1",
";",
"}",
"else",
"{",
"int",
"[",
"]",
"parts",
"=",
"findSubexpression",
"(",
"index",
")",
";",
"int",
"parent... | Get the index of the parent expression that contains the given index.
Returns -1 if the indexed expression has no parent.
@param index
@return | [
"Get",
"the",
"index",
"of",
"the",
"parent",
"expression",
"that",
"contains",
"the",
"given",
"index",
".",
"Returns",
"-",
"1",
"if",
"the",
"indexed",
"expression",
"has",
"no",
"parent",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/lambda2/Expression2.java#L144-L160 | train |
jayantk/jklol | src/com/jayantkrish/jklol/lisp/inc/ContinuationIncEval.java | ContinuationIncEval.nextState | public void nextState(IncEvalState prev, IncEvalState next, Object continuation,
Environment env, Object denotation, Object diagram, Object otherArgs, LogFunction log) {
next.set(continuation, env, denotation, diagram, prev.getProb(), null);
} | java | public void nextState(IncEvalState prev, IncEvalState next, Object continuation,
Environment env, Object denotation, Object diagram, Object otherArgs, LogFunction log) {
next.set(continuation, env, denotation, diagram, prev.getProb(), null);
} | [
"public",
"void",
"nextState",
"(",
"IncEvalState",
"prev",
",",
"IncEvalState",
"next",
",",
"Object",
"continuation",
",",
"Environment",
"env",
",",
"Object",
"denotation",
",",
"Object",
"diagram",
",",
"Object",
"otherArgs",
",",
"LogFunction",
"log",
")",
... | Override this method in subclasses to implement scoring of search states
and accumulating features.
@return | [
"Override",
"this",
"method",
"in",
"subclasses",
"to",
"implement",
"scoring",
"of",
"search",
"states",
"and",
"accumulating",
"features",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/lisp/inc/ContinuationIncEval.java#L135-L138 | train |
ivanceras/orm | src/main/java/com/ivanceras/db/shared/datatype/DataTypeGeneric.java | DataTypeGeneric.convert | public static Object convert(String dataType, Object record){
if(record == null){return null;}
if(dataType.equals(UUID)){
return java.util.UUID.fromString(record.toString());
}
//TODO: add a lot of else if here for the other data types
else{
return record;
}
} | java | public static Object convert(String dataType, Object record){
if(record == null){return null;}
if(dataType.equals(UUID)){
return java.util.UUID.fromString(record.toString());
}
//TODO: add a lot of else if here for the other data types
else{
return record;
}
} | [
"public",
"static",
"Object",
"convert",
"(",
"String",
"dataType",
",",
"Object",
"record",
")",
"{",
"if",
"(",
"record",
"==",
"null",
")",
"{",
"return",
"null",
";",
"}",
"if",
"(",
"dataType",
".",
"equals",
"(",
"UUID",
")",
")",
"{",
"return"... | Based on the generic data type convert record to an appropriate Java Data type
@param dataType
@param record | [
"Based",
"on",
"the",
"generic",
"data",
"type",
"convert",
"record",
"to",
"an",
"appropriate",
"Java",
"Data",
"type"
] | e63213cb8abefd11df0e2d34b1c95477788e600e | https://github.com/ivanceras/orm/blob/e63213cb8abefd11df0e2d34b1c95477788e600e/src/main/java/com/ivanceras/db/shared/datatype/DataTypeGeneric.java#L106-L115 | train |
ivanceras/orm | src/main/java/com/ivanceras/db/server/util/ModelCurator.java | ModelCurator.correct | public ModelDef[] correct(){
for(ModelDef m : modelList){
this.model = m;
correct1to1Detail();
}
for(ModelDef m : modelList){
this.model = m;
removeUnnecessaryHasOneToSelf();
}
for(ModelDef m : modelList){
this.model = m;
removeUnnecessaryHasManyToSelf();
}
for(ModelDef m : modelList){
... | java | public ModelDef[] correct(){
for(ModelDef m : modelList){
this.model = m;
correct1to1Detail();
}
for(ModelDef m : modelList){
this.model = m;
removeUnnecessaryHasOneToSelf();
}
for(ModelDef m : modelList){
this.model = m;
removeUnnecessaryHasManyToSelf();
}
for(ModelDef m : modelList){
... | [
"public",
"ModelDef",
"[",
"]",
"correct",
"(",
")",
"{",
"for",
"(",
"ModelDef",
"m",
":",
"modelList",
")",
"{",
"this",
".",
"model",
"=",
"m",
";",
"correct1to1Detail",
"(",
")",
";",
"}",
"for",
"(",
"ModelDef",
"m",
":",
"modelList",
")",
"{"... | Run each one at a time for all models in such a way that it won't disturb the other
@return | [
"Run",
"each",
"one",
"at",
"a",
"time",
"for",
"all",
"models",
"in",
"such",
"a",
"way",
"that",
"it",
"won",
"t",
"disturb",
"the",
"other"
] | e63213cb8abefd11df0e2d34b1c95477788e600e | https://github.com/ivanceras/orm/blob/e63213cb8abefd11df0e2d34b1c95477788e600e/src/main/java/com/ivanceras/db/server/util/ModelCurator.java#L25-L47 | train |
ivanceras/orm | src/main/java/com/ivanceras/db/server/util/ModelCurator.java | ModelCurator.removeHasOneToBothPrimaryAndForeignKey | private void removeHasOneToBothPrimaryAndForeignKey() {
String[] primaryKeys = model.getPrimaryAttributes();
String[] hasOne = model.getHasOne();
String[] hasOneLocal = model.getHasOneLocalColumn();
String[] hasOneReferenced = model.getHasOneReferencedColumn();
for(String pk : primaryKeys){
int pkIndex = C... | java | private void removeHasOneToBothPrimaryAndForeignKey() {
String[] primaryKeys = model.getPrimaryAttributes();
String[] hasOne = model.getHasOne();
String[] hasOneLocal = model.getHasOneLocalColumn();
String[] hasOneReferenced = model.getHasOneReferencedColumn();
for(String pk : primaryKeys){
int pkIndex = C... | [
"private",
"void",
"removeHasOneToBothPrimaryAndForeignKey",
"(",
")",
"{",
"String",
"[",
"]",
"primaryKeys",
"=",
"model",
".",
"getPrimaryAttributes",
"(",
")",
";",
"String",
"[",
"]",
"hasOne",
"=",
"model",
".",
"getHasOne",
"(",
")",
";",
"String",
"[... | user_info.user_id is the primary key while it is refering to users.user_id
user_info.User will create a cyclic recursive mapping to users and user_info and back.
Remove that hasOne which is both primary and foreign to prevent that. | [
"user_info",
".",
"user_id",
"is",
"the",
"primary",
"key",
"while",
"it",
"is",
"refering",
"to",
"users",
".",
"user_id",
"user_info",
".",
"User",
"will",
"create",
"a",
"cyclic",
"recursive",
"mapping",
"to",
"users",
"and",
"user_info",
"and",
"back",
... | e63213cb8abefd11df0e2d34b1c95477788e600e | https://github.com/ivanceras/orm/blob/e63213cb8abefd11df0e2d34b1c95477788e600e/src/main/java/com/ivanceras/db/server/util/ModelCurator.java#L56-L70 | train |
ivanceras/orm | src/main/java/com/ivanceras/db/server/util/ModelCurator.java | ModelCurator.correct1to1Detail | private void correct1to1Detail(){
String[] hasManyTables = model.getHasMany();
for(String hasMany : hasManyTables){
if(shouldBeMoved(model, hasMany)){
model = moveFromHasManyToHasOne(model, hasMany);
}
}
} | java | private void correct1to1Detail(){
String[] hasManyTables = model.getHasMany();
for(String hasMany : hasManyTables){
if(shouldBeMoved(model, hasMany)){
model = moveFromHasManyToHasOne(model, hasMany);
}
}
} | [
"private",
"void",
"correct1to1Detail",
"(",
")",
"{",
"String",
"[",
"]",
"hasManyTables",
"=",
"model",
".",
"getHasMany",
"(",
")",
";",
"for",
"(",
"String",
"hasMany",
":",
"hasManyTables",
")",
"{",
"if",
"(",
"shouldBeMoved",
"(",
"model",
",",
"h... | If the localColum of that hasMany table is the primary attributes AND it refer to the primary column of this table
users.primaryKey = [user_id]
users.hasMany = [user_info]
users.hasManyLocal = [user_id]
users.hasManyReference = [user_id]
user_info.primaryKey = [user_id]
user_info.hasOne = [users]
user_info.hasOneLoca... | [
"If",
"the",
"localColum",
"of",
"that",
"hasMany",
"table",
"is",
"the",
"primary",
"attributes",
"AND",
"it",
"refer",
"to",
"the",
"primary",
"column",
"of",
"this",
"table"
] | e63213cb8abefd11df0e2d34b1c95477788e600e | https://github.com/ivanceras/orm/blob/e63213cb8abefd11df0e2d34b1c95477788e600e/src/main/java/com/ivanceras/db/server/util/ModelCurator.java#L88-L96 | train |
ivanceras/orm | src/main/java/com/ivanceras/db/server/util/ModelCurator.java | ModelCurator.crossOutLinkerTables | private void crossOutLinkerTables(){
String[] primaryKeys = model.getPrimaryAttributes();
if(primaryKeys != null && primaryKeys.length == 2){//there are only 2 primary keys
//if both primary keys look up to different table which is also a primary key
String[] hasOne = model.getHasOne();
String[] hasOneLoca... | java | private void crossOutLinkerTables(){
String[] primaryKeys = model.getPrimaryAttributes();
if(primaryKeys != null && primaryKeys.length == 2){//there are only 2 primary keys
//if both primary keys look up to different table which is also a primary key
String[] hasOne = model.getHasOne();
String[] hasOneLoca... | [
"private",
"void",
"crossOutLinkerTables",
"(",
")",
"{",
"String",
"[",
"]",
"primaryKeys",
"=",
"model",
".",
"getPrimaryAttributes",
"(",
")",
";",
"if",
"(",
"primaryKeys",
"!=",
"null",
"&&",
"primaryKeys",
".",
"length",
"==",
"2",
")",
"{",
"//there... | Remove a linker table present in the hasMany, then short circuit right away to the linked table
Linker tables contains composite primary keys of two tables
If each local column of the primary key is the primary of the table it is referring to
the this is a lookup table
ie. product, product_category, category
Product ... | [
"Remove",
"a",
"linker",
"table",
"present",
"in",
"the",
"hasMany",
"then",
"short",
"circuit",
"right",
"away",
"to",
"the",
"linked",
"table"
] | e63213cb8abefd11df0e2d34b1c95477788e600e | https://github.com/ivanceras/orm/blob/e63213cb8abefd11df0e2d34b1c95477788e600e/src/main/java/com/ivanceras/db/server/util/ModelCurator.java#L282-L321 | train |
jayantk/jklol | src/com/jayantkrish/jklol/preprocessing/DictionaryFeatureVectorGenerator.java | DictionaryFeatureVectorGenerator.getActiveFeatures | public Map<U, Double> getActiveFeatures(Tensor featureVector) {
Preconditions.checkArgument(featureVector.getDimensionSizes().length == 1
&& featureVector.getDimensionSizes()[0] == getNumberOfFeatures());
Map<U, Double> features = Maps.newHashMap();
Iterator<KeyValue> keyValueIter = featureVector.k... | java | public Map<U, Double> getActiveFeatures(Tensor featureVector) {
Preconditions.checkArgument(featureVector.getDimensionSizes().length == 1
&& featureVector.getDimensionSizes()[0] == getNumberOfFeatures());
Map<U, Double> features = Maps.newHashMap();
Iterator<KeyValue> keyValueIter = featureVector.k... | [
"public",
"Map",
"<",
"U",
",",
"Double",
">",
"getActiveFeatures",
"(",
"Tensor",
"featureVector",
")",
"{",
"Preconditions",
".",
"checkArgument",
"(",
"featureVector",
".",
"getDimensionSizes",
"(",
")",
".",
"length",
"==",
"1",
"&&",
"featureVector",
".",... | Given a feature vector, get the features which were active for
it. This method inverts the mapping from feature sets to feature
vectors performed by this class.
@param featureVector
@return | [
"Given",
"a",
"feature",
"vector",
"get",
"the",
"features",
"which",
"were",
"active",
"for",
"it",
".",
"This",
"method",
"inverts",
"the",
"mapping",
"from",
"feature",
"sets",
"to",
"feature",
"vectors",
"performed",
"by",
"this",
"class",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/preprocessing/DictionaryFeatureVectorGenerator.java#L135-L146 | train |
getlantern/kaleidoscope | src/main/java/org/kaleidoscope/LocalTrustGraph.java | LocalTrustGraph.sendAdvertisement | public void sendAdvertisement(final BasicTrustGraphAdvertisement message,
final TrustGraphNodeId sender,
final TrustGraphNodeId toNeighbor,
final int ttl) {
final BasicTrustGraphAdvertisement outboundMessage = ... | java | public void sendAdvertisement(final BasicTrustGraphAdvertisement message,
final TrustGraphNodeId sender,
final TrustGraphNodeId toNeighbor,
final int ttl) {
final BasicTrustGraphAdvertisement outboundMessage = ... | [
"public",
"void",
"sendAdvertisement",
"(",
"final",
"BasicTrustGraphAdvertisement",
"message",
",",
"final",
"TrustGraphNodeId",
"sender",
",",
"final",
"TrustGraphNodeId",
"toNeighbor",
",",
"final",
"int",
"ttl",
")",
"{",
"final",
"BasicTrustGraphAdvertisement",
"ou... | send a local advertisement to the node specified with
the given ttl.
@param message advertisement to send
@param sender the node sending the message
@param toNeighbor the recipient of the message | [
"send",
"a",
"local",
"advertisement",
"to",
"the",
"node",
"specified",
"with",
"the",
"given",
"ttl",
"."
] | 7516f05724c8f54e5d535d23da9116817c08a09f | https://github.com/getlantern/kaleidoscope/blob/7516f05724c8f54e5d535d23da9116817c08a09f/src/main/java/org/kaleidoscope/LocalTrustGraph.java#L149-L156 | train |
getlantern/kaleidoscope | src/main/java/org/kaleidoscope/LocalTrustGraph.java | LocalTrustGraph.addNode | public LocalTrustGraphNode addNode(final TrustGraphNodeId nodeId) {
final LocalTrustGraphNode node = createNode(nodeId);
addNode(node);
return node;
} | java | public LocalTrustGraphNode addNode(final TrustGraphNodeId nodeId) {
final LocalTrustGraphNode node = createNode(nodeId);
addNode(node);
return node;
} | [
"public",
"LocalTrustGraphNode",
"addNode",
"(",
"final",
"TrustGraphNodeId",
"nodeId",
")",
"{",
"final",
"LocalTrustGraphNode",
"node",
"=",
"createNode",
"(",
"nodeId",
")",
";",
"addNode",
"(",
"node",
")",
";",
"return",
"node",
";",
"}"
] | Create and add a new trust graph node with the given id.
@param nodeId the identifier for the new node
@returns the new node | [
"Create",
"and",
"add",
"a",
"new",
"trust",
"graph",
"node",
"with",
"the",
"given",
"id",
"."
] | 7516f05724c8f54e5d535d23da9116817c08a09f | https://github.com/getlantern/kaleidoscope/blob/7516f05724c8f54e5d535d23da9116817c08a09f/src/main/java/org/kaleidoscope/LocalTrustGraph.java#L175-L179 | train |
getlantern/kaleidoscope | src/main/java/org/kaleidoscope/LocalTrustGraph.java | LocalTrustGraph.addDirectedRoute | public void addDirectedRoute(final LocalTrustGraphNode from, final LocalTrustGraphNode to) {
from.getRoutingTable().addNeighbor(to.getId());
} | java | public void addDirectedRoute(final LocalTrustGraphNode from, final LocalTrustGraphNode to) {
from.getRoutingTable().addNeighbor(to.getId());
} | [
"public",
"void",
"addDirectedRoute",
"(",
"final",
"LocalTrustGraphNode",
"from",
",",
"final",
"LocalTrustGraphNode",
"to",
")",
"{",
"from",
".",
"getRoutingTable",
"(",
")",
".",
"addNeighbor",
"(",
"to",
".",
"getId",
"(",
")",
")",
";",
"}"
] | Add a directed trust graph link between two nodes.
Note: Although this is useful for testing adverse conditions,
relationships must be symmetric for the normal functioning of
the algorithm. An advertising node must trust another node to
send to it, and that same node must trust the sender in order
to forward the mess... | [
"Add",
"a",
"directed",
"trust",
"graph",
"link",
"between",
"two",
"nodes",
"."
] | 7516f05724c8f54e5d535d23da9116817c08a09f | https://github.com/getlantern/kaleidoscope/blob/7516f05724c8f54e5d535d23da9116817c08a09f/src/main/java/org/kaleidoscope/LocalTrustGraph.java#L231-L233 | train |
getlantern/kaleidoscope | src/main/java/org/kaleidoscope/LocalTrustGraph.java | LocalTrustGraph.addDirectedRoute | public void addDirectedRoute(final TrustGraphNodeId from, final TrustGraphNodeId to) {
final TrustGraphNode fromNode = nodes.get(from);
fromNode.getRoutingTable().addNeighbor(to);
} | java | public void addDirectedRoute(final TrustGraphNodeId from, final TrustGraphNodeId to) {
final TrustGraphNode fromNode = nodes.get(from);
fromNode.getRoutingTable().addNeighbor(to);
} | [
"public",
"void",
"addDirectedRoute",
"(",
"final",
"TrustGraphNodeId",
"from",
",",
"final",
"TrustGraphNodeId",
"to",
")",
"{",
"final",
"TrustGraphNode",
"fromNode",
"=",
"nodes",
".",
"get",
"(",
"from",
")",
";",
"fromNode",
".",
"getRoutingTable",
"(",
"... | create a directed trust link between two nodes. The node with id 'from' will
trust the node with id 'to'.
Note: Although this is useful for testing adverse conditions,
relationships must be symmetric for the normal functioning of
the algorithm. An advertising node must trust another node to
send to it, and that same ... | [
"create",
"a",
"directed",
"trust",
"link",
"between",
"two",
"nodes",
".",
"The",
"node",
"with",
"id",
"from",
"will",
"trust",
"the",
"node",
"with",
"id",
"to",
"."
] | 7516f05724c8f54e5d535d23da9116817c08a09f | https://github.com/getlantern/kaleidoscope/blob/7516f05724c8f54e5d535d23da9116817c08a09f/src/main/java/org/kaleidoscope/LocalTrustGraph.java#L249-L252 | train |
getlantern/kaleidoscope | src/main/java/org/kaleidoscope/LocalTrustGraph.java | LocalTrustGraph.addRoute | public void addRoute(final TrustGraphNodeId a, final TrustGraphNodeId b) {
addDirectedRoute(a,b);
addDirectedRoute(b,a);
} | java | public void addRoute(final TrustGraphNodeId a, final TrustGraphNodeId b) {
addDirectedRoute(a,b);
addDirectedRoute(b,a);
} | [
"public",
"void",
"addRoute",
"(",
"final",
"TrustGraphNodeId",
"a",
",",
"final",
"TrustGraphNodeId",
"b",
")",
"{",
"addDirectedRoute",
"(",
"a",
",",
"b",
")",
";",
"addDirectedRoute",
"(",
"b",
",",
"a",
")",
";",
"}"
] | create a bidirectional trust link between the nodes with ids 'a' and 'b'
@param a id of node that will form a trust link with 'b'
@param b id of node that will form a trust link with 'a' | [
"create",
"a",
"bidirectional",
"trust",
"link",
"between",
"the",
"nodes",
"with",
"ids",
"a",
"and",
"b"
] | 7516f05724c8f54e5d535d23da9116817c08a09f | https://github.com/getlantern/kaleidoscope/blob/7516f05724c8f54e5d535d23da9116817c08a09f/src/main/java/org/kaleidoscope/LocalTrustGraph.java#L260-L263 | train |
getlantern/kaleidoscope | src/main/java/org/kaleidoscope/LocalTrustGraph.java | LocalTrustGraph.addRoute | public void addRoute(final LocalTrustGraphNode a, final LocalTrustGraphNode b) {
addDirectedRoute(a,b);
addDirectedRoute(b,a);
} | java | public void addRoute(final LocalTrustGraphNode a, final LocalTrustGraphNode b) {
addDirectedRoute(a,b);
addDirectedRoute(b,a);
} | [
"public",
"void",
"addRoute",
"(",
"final",
"LocalTrustGraphNode",
"a",
",",
"final",
"LocalTrustGraphNode",
"b",
")",
"{",
"addDirectedRoute",
"(",
"a",
",",
"b",
")",
";",
"addDirectedRoute",
"(",
"b",
",",
"a",
")",
";",
"}"
] | add bidirectioanl trust graph links between two nodes.
@param a node that will form a trust link with 'b'
@param b node that will form a trust link with 'a' | [
"add",
"bidirectioanl",
"trust",
"graph",
"links",
"between",
"two",
"nodes",
"."
] | 7516f05724c8f54e5d535d23da9116817c08a09f | https://github.com/getlantern/kaleidoscope/blob/7516f05724c8f54e5d535d23da9116817c08a09f/src/main/java/org/kaleidoscope/LocalTrustGraph.java#L271-L274 | train |
HiddenStage/divide | Client/java-client/src/main/java/io/divide/client/http/Status.java | Status.valueOf | public static Status valueOf(int code) {
Status result = null;
switch (code) {
case 100:
result = INFO_CONTINUE;
break;
case 101:
result = INFO_SWITCHING_PROTOCOL;
break;
case 102:
result... | java | public static Status valueOf(int code) {
Status result = null;
switch (code) {
case 100:
result = INFO_CONTINUE;
break;
case 101:
result = INFO_SWITCHING_PROTOCOL;
break;
case 102:
result... | [
"public",
"static",
"Status",
"valueOf",
"(",
"int",
"code",
")",
"{",
"Status",
"result",
"=",
"null",
";",
"switch",
"(",
"code",
")",
"{",
"case",
"100",
":",
"result",
"=",
"INFO_CONTINUE",
";",
"break",
";",
"case",
"101",
":",
"result",
"=",
"I... | Returns the status associated to a code. If an existing constant exists
then it is returned, otherwise a new instance is created.
@param code
The code.
@return The associated status. | [
"Returns",
"the",
"status",
"associated",
"to",
"a",
"code",
".",
"If",
"an",
"existing",
"constant",
"exists",
"then",
"it",
"is",
"returned",
"otherwise",
"a",
"new",
"instance",
"is",
"created",
"."
] | 14e36598c50d92b4393e6649915e32b86141c598 | https://github.com/HiddenStage/divide/blob/14e36598c50d92b4393e6649915e32b86141c598/Client/java-client/src/main/java/io/divide/client/http/Status.java#L707-L866 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java | BasicPopulateFactory.populateEntity | private <T> T populateEntity(final T t,
final Map<Field, Long> enumeratesMap,
final Set<Field> nullableFields,
final int currentEmbeddedDepth) {
final Map<Field, GenContainer> genContainers = this.populateScanner.... | java | private <T> T populateEntity(final T t,
final Map<Field, Long> enumeratesMap,
final Set<Field> nullableFields,
final int currentEmbeddedDepth) {
final Map<Field, GenContainer> genContainers = this.populateScanner.... | [
"private",
"<",
"T",
">",
"T",
"populateEntity",
"(",
"final",
"T",
"t",
",",
"final",
"Map",
"<",
"Field",
",",
"Long",
">",
"enumeratesMap",
",",
"final",
"Set",
"<",
"Field",
">",
"nullableFields",
",",
"final",
"int",
"currentEmbeddedDepth",
")",
"{"... | Populate single entity
@param t entity to populate
@param enumeratesMap map of enumerated marked fields
@param nullableFields set with fields that had errors in
@param currentEmbeddedDepth embedded depth level
@return populated entity | [
"Populate",
"single",
"entity"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java#L68-L102 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java | BasicPopulateFactory.generateObject | private Object generateObject(final Field field,
final GenContainer container,
final Map<Field, Long> enumerateMap,
final Set<Field> nullableFields,
final int currentEmbeddedDepth) {
... | java | private Object generateObject(final Field field,
final GenContainer container,
final Map<Field, Long> enumerateMap,
final Set<Field> nullableFields,
final int currentEmbeddedDepth) {
... | [
"private",
"Object",
"generateObject",
"(",
"final",
"Field",
"field",
",",
"final",
"GenContainer",
"container",
",",
"final",
"Map",
"<",
"Field",
",",
"Long",
">",
"enumerateMap",
",",
"final",
"Set",
"<",
"Field",
">",
"nullableFields",
",",
"final",
"in... | Generate populate field value
@param field field to populate
@param container field populate annotations
@param enumerateMap field enumerate map
@param nullableFields set with fields that had errors in | [
"Generate",
"populate",
"field",
"value"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java#L112-L139 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java | BasicPopulateFactory.generateEmbeddedObject | private Object generateEmbeddedObject(final Annotation annotation,
final Field field,
final Set<Field> nullableFields,
final int currentEmbeddedDepth) {
final int fieldDepth = getDepth(a... | java | private Object generateEmbeddedObject(final Annotation annotation,
final Field field,
final Set<Field> nullableFields,
final int currentEmbeddedDepth) {
final int fieldDepth = getDepth(a... | [
"private",
"Object",
"generateEmbeddedObject",
"(",
"final",
"Annotation",
"annotation",
",",
"final",
"Field",
"field",
",",
"final",
"Set",
"<",
"Field",
">",
"nullableFields",
",",
"final",
"int",
"currentEmbeddedDepth",
")",
"{",
"final",
"int",
"fieldDepth",
... | Generate embedded field value
@param field field with embedded value
@param nullableFields set with fields that had errors in | [
"Generate",
"embedded",
"field",
"value"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java#L147-L165 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java | BasicPopulateFactory.generateEnumerateObject | private Object generateEnumerateObject(final Field field,
final Map<Field, Long> enumerateMap) {
final Long currentEnumerateValue = enumerateMap.get(field);
Object objValue = BasicCastUtils.castToNumber(currentEnumerateValue, field.getType());
// Incre... | java | private Object generateEnumerateObject(final Field field,
final Map<Field, Long> enumerateMap) {
final Long currentEnumerateValue = enumerateMap.get(field);
Object objValue = BasicCastUtils.castToNumber(currentEnumerateValue, field.getType());
// Incre... | [
"private",
"Object",
"generateEnumerateObject",
"(",
"final",
"Field",
"field",
",",
"final",
"Map",
"<",
"Field",
",",
"Long",
">",
"enumerateMap",
")",
"{",
"final",
"Long",
"currentEnumerateValue",
"=",
"enumerateMap",
".",
"get",
"(",
"field",
")",
";",
... | Generate enumerate field next value | [
"Generate",
"enumerate",
"field",
"next",
"value"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java#L170-L178 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java | BasicPopulateFactory.buildEnumerateMap | private Map<Field, Long> buildEnumerateMap(final Class t) {
return this.enumerateScanner.scan(t).entrySet().stream()
.collect(Collectors.toMap(
Map.Entry::getKey,
e -> ((GenEnumerate) e.getValue().get(0)).from())
);
} | java | private Map<Field, Long> buildEnumerateMap(final Class t) {
return this.enumerateScanner.scan(t).entrySet().stream()
.collect(Collectors.toMap(
Map.Entry::getKey,
e -> ((GenEnumerate) e.getValue().get(0)).from())
);
} | [
"private",
"Map",
"<",
"Field",
",",
"Long",
">",
"buildEnumerateMap",
"(",
"final",
"Class",
"t",
")",
"{",
"return",
"this",
".",
"enumerateScanner",
".",
"scan",
"(",
"t",
")",
".",
"entrySet",
"(",
")",
".",
"stream",
"(",
")",
".",
"collect",
"(... | Setup map for enumerate fields
@param t class to scan for enumerate fields | [
"Setup",
"map",
"for",
"enumerate",
"fields"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/factory/impl/BasicPopulateFactory.java#L236-L242 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/lexinduct/CfgAlignmentModel.java | CfgAlignmentModel.getRootFactor | public Factor getRootFactor(ExpressionTree tree, VariableNumMap expressionVar) {
List<Assignment> roots = Lists.newArrayList();
if (tree.getSubstitutions().size() == 0) {
roots.add(expressionVar.outcomeArrayToAssignment(tree.getExpressionNode()));
} else {
for (ExpressionTree substitution : tree... | java | public Factor getRootFactor(ExpressionTree tree, VariableNumMap expressionVar) {
List<Assignment> roots = Lists.newArrayList();
if (tree.getSubstitutions().size() == 0) {
roots.add(expressionVar.outcomeArrayToAssignment(tree.getExpressionNode()));
} else {
for (ExpressionTree substitution : tree... | [
"public",
"Factor",
"getRootFactor",
"(",
"ExpressionTree",
"tree",
",",
"VariableNumMap",
"expressionVar",
")",
"{",
"List",
"<",
"Assignment",
">",
"roots",
"=",
"Lists",
".",
"newArrayList",
"(",
")",
";",
"if",
"(",
"tree",
".",
"getSubstitutions",
"(",
... | This method is a hack that enables the use of the "substitutions"
field of ExpressionTree at the root of the CFG parse. In the future,
these substitutions should be handled using unary rules in the
CFG parser. | [
"This",
"method",
"is",
"a",
"hack",
"that",
"enables",
"the",
"use",
"of",
"the",
"substitutions",
"field",
"of",
"ExpressionTree",
"at",
"the",
"root",
"of",
"the",
"CFG",
"parse",
".",
"In",
"the",
"future",
"these",
"substitutions",
"should",
"be",
"ha... | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/lexinduct/CfgAlignmentModel.java#L327-L338 | train |
lastaflute/lasta-job | src/main/java/org/lastaflute/job/cron4j/Cron4jNow.java | Cron4jNow.clearDisappearedJob | public synchronized void clearDisappearedJob() {
getCron4jJobList().stream().filter(job -> job.isDisappeared()).forEach(job -> {
final LaJobKey jobKey = job.getJobKey();
jobKeyJobMap.remove(jobKey);
jobOrderedList.remove(job);
job.getJobUnique().ifPresent(jobUniqu... | java | public synchronized void clearDisappearedJob() {
getCron4jJobList().stream().filter(job -> job.isDisappeared()).forEach(job -> {
final LaJobKey jobKey = job.getJobKey();
jobKeyJobMap.remove(jobKey);
jobOrderedList.remove(job);
job.getJobUnique().ifPresent(jobUniqu... | [
"public",
"synchronized",
"void",
"clearDisappearedJob",
"(",
")",
"{",
"getCron4jJobList",
"(",
")",
".",
"stream",
"(",
")",
".",
"filter",
"(",
"job",
"->",
"job",
".",
"isDisappeared",
"(",
")",
")",
".",
"forEach",
"(",
"job",
"->",
"{",
"final",
... | Clear disappeared jobs from job list if it exists. | [
"Clear",
"disappeared",
"jobs",
"from",
"job",
"list",
"if",
"it",
"exists",
"."
] | 5fee7bb1e908463c56b4668de404fd8bce1c2710 | https://github.com/lastaflute/lasta-job/blob/5fee7bb1e908463c56b4668de404fd8bce1c2710/src/main/java/org/lastaflute/job/cron4j/Cron4jNow.java#L230-L238 | train |
jayantk/jklol | src/com/jayantkrish/jklol/models/dynamic/DynamicFactorGraphBuilder.java | DynamicFactorGraphBuilder.addUnreplicatedFactor | public void addUnreplicatedFactor(String factorName, Factor factor, VariableNumMap vars) {
plateFactors.add(new ReplicatedFactor(factor, new WrapperVariablePattern(vars)));
plateFactorNames.add(factorName);
} | java | public void addUnreplicatedFactor(String factorName, Factor factor, VariableNumMap vars) {
plateFactors.add(new ReplicatedFactor(factor, new WrapperVariablePattern(vars)));
plateFactorNames.add(factorName);
} | [
"public",
"void",
"addUnreplicatedFactor",
"(",
"String",
"factorName",
",",
"Factor",
"factor",
",",
"VariableNumMap",
"vars",
")",
"{",
"plateFactors",
".",
"add",
"(",
"new",
"ReplicatedFactor",
"(",
"factor",
",",
"new",
"WrapperVariablePattern",
"(",
"vars",
... | Adds an unreplicated factor to the model being
constructed. The factor will match only the variables which it is
defined over.
@param factor | [
"Adds",
"an",
"unreplicated",
"factor",
"to",
"the",
"model",
"being",
"constructed",
".",
"The",
"factor",
"will",
"match",
"only",
"the",
"variables",
"which",
"it",
"is",
"defined",
"over",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/models/dynamic/DynamicFactorGraphBuilder.java#L33-L36 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/scan/impl/PopulateScanner.java | PopulateScanner.isComplex | private boolean isComplex(final Field field) {
final Class<?> declaringClass = field.getType();
return (declaringClass.equals(List.class)
|| declaringClass.equals(Set.class)
|| declaringClass.equals(Map.class))
|| declaringClass.getTypeName().endsWith("[][... | java | private boolean isComplex(final Field field) {
final Class<?> declaringClass = field.getType();
return (declaringClass.equals(List.class)
|| declaringClass.equals(Set.class)
|| declaringClass.equals(Map.class))
|| declaringClass.getTypeName().endsWith("[][... | [
"private",
"boolean",
"isComplex",
"(",
"final",
"Field",
"field",
")",
"{",
"final",
"Class",
"<",
"?",
">",
"declaringClass",
"=",
"field",
".",
"getType",
"(",
")",
";",
"return",
"(",
"declaringClass",
".",
"equals",
"(",
"List",
".",
"class",
")",
... | Check if the field have complex suitable generator | [
"Check",
"if",
"the",
"field",
"have",
"complex",
"suitable",
"generator"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/scan/impl/PopulateScanner.java#L86-L93 | train |
GoodforGod/dummymaker | src/main/java/io/dummymaker/scan/impl/PopulateScanner.java | PopulateScanner.findGenAnnotation | private GenContainer findGenAnnotation(final Field field) {
for (Annotation annotation : field.getDeclaredAnnotations()) {
for (Annotation inline : annotation.annotationType().getDeclaredAnnotations()) {
if (isGen.test(inline)) {
return GenContainer.asGen(inline, ... | java | private GenContainer findGenAnnotation(final Field field) {
for (Annotation annotation : field.getDeclaredAnnotations()) {
for (Annotation inline : annotation.annotationType().getDeclaredAnnotations()) {
if (isGen.test(inline)) {
return GenContainer.asGen(inline, ... | [
"private",
"GenContainer",
"findGenAnnotation",
"(",
"final",
"Field",
"field",
")",
"{",
"for",
"(",
"Annotation",
"annotation",
":",
"field",
".",
"getDeclaredAnnotations",
"(",
")",
")",
"{",
"for",
"(",
"Annotation",
"inline",
":",
"annotation",
".",
"anno... | Found only first found gen annotation on field | [
"Found",
"only",
"first",
"found",
"gen",
"annotation",
"on",
"field"
] | a4809c0a8139ab9cdb42814a3e37772717a313b4 | https://github.com/GoodforGod/dummymaker/blob/a4809c0a8139ab9cdb42814a3e37772717a313b4/src/main/java/io/dummymaker/scan/impl/PopulateScanner.java#L98-L108 | train |
jayantk/jklol | src/com/jayantkrish/jklol/ccg/augment/DavidsonianCcgParseAugmenter.java | DavidsonianCcgParseAugmenter.markEntityVars | private static void markEntityVars(HeadedSyntacticCategory cat, int[] uniqueVars,
boolean[] isEntityVar) {
if (cat.isAtomic()) {
for (int var : cat.getUniqueVariables()) {
int index = Ints.indexOf(uniqueVars, var);
isEntityVar[index] = true;
}
} else {
markEntityVars(cat.... | java | private static void markEntityVars(HeadedSyntacticCategory cat, int[] uniqueVars,
boolean[] isEntityVar) {
if (cat.isAtomic()) {
for (int var : cat.getUniqueVariables()) {
int index = Ints.indexOf(uniqueVars, var);
isEntityVar[index] = true;
}
} else {
markEntityVars(cat.... | [
"private",
"static",
"void",
"markEntityVars",
"(",
"HeadedSyntacticCategory",
"cat",
",",
"int",
"[",
"]",
"uniqueVars",
",",
"boolean",
"[",
"]",
"isEntityVar",
")",
"{",
"if",
"(",
"cat",
".",
"isAtomic",
"(",
")",
")",
"{",
"for",
"(",
"int",
"var",
... | Marks all unique variables in a syntactic category
associated with atomic syntactic categories. | [
"Marks",
"all",
"unique",
"variables",
"in",
"a",
"syntactic",
"category",
"associated",
"with",
"atomic",
"syntactic",
"categories",
"."
] | d27532ca83e212d51066cf28f52621acc3fd44cc | https://github.com/jayantk/jklol/blob/d27532ca83e212d51066cf28f52621acc3fd44cc/src/com/jayantkrish/jklol/ccg/augment/DavidsonianCcgParseAugmenter.java#L239-L250 | train |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.