id
int32
0
165k
repo
stringlengths
7
58
path
stringlengths
12
218
func_name
stringlengths
3
140
original_string
stringlengths
73
34.1k
language
stringclasses
1 value
code
stringlengths
73
34.1k
code_tokens
list
docstring
stringlengths
3
16k
docstring_tokens
list
sha
stringlengths
40
40
url
stringlengths
105
339
152,700
drewwills/cernunnos
cernunnos-core/src/main/java/org/danann/cernunnos/runtime/web/Settings.java
Settings.locateContextConfig
public static URL locateContextConfig(String webappRootContext, String userSpecifiedContextLocation, URL defaultLocation) { // Assertions. if (webappRootContext == null) { String msg = "Argument 'webappRootContext' cannot be null."; throw new IllegalArgumentException(msg); ...
java
public static URL locateContextConfig(String webappRootContext, String userSpecifiedContextLocation, URL defaultLocation) { // Assertions. if (webappRootContext == null) { String msg = "Argument 'webappRootContext' cannot be null."; throw new IllegalArgumentException(msg); ...
[ "public", "static", "URL", "locateContextConfig", "(", "String", "webappRootContext", ",", "String", "userSpecifiedContextLocation", ",", "URL", "defaultLocation", ")", "{", "// Assertions.", "if", "(", "webappRootContext", "==", "null", ")", "{", "String", "msg", "...
Locate the configuration file, if present, for a Portlet or Servlet. @param webappRootContext Context URL (in String form) from which <code>userSpecifiedContextLocation</code> will be evaluated by <code>ResourceHelper</code>, if specified @param userSpecifiedContextLocation Optional location specified in the deploymen...
[ "Locate", "the", "configuration", "file", "if", "present", "for", "a", "Portlet", "or", "Servlet", "." ]
dc6848e0253775e22b6c869fd06506d4ddb6d728
https://github.com/drewwills/cernunnos/blob/dc6848e0253775e22b6c869fd06506d4ddb6d728/cernunnos-core/src/main/java/org/danann/cernunnos/runtime/web/Settings.java#L64-L95
152,701
kirgor/enklib
compile/src/main/java/com/kirgor/enklib/compile/CompileUtils.java
CompileUtils.compileClass
public static Class compileClass(String name, String code, List<Class> classPath) throws Exception { JavaCompiler compiler = ToolProvider.getSystemJavaCompiler(); DiagnosticCollector<JavaFileObject> diagnostics = new DiagnosticCollector<JavaFileObject>(); MemoryJavaFileManager fileManager = new ...
java
public static Class compileClass(String name, String code, List<Class> classPath) throws Exception { JavaCompiler compiler = ToolProvider.getSystemJavaCompiler(); DiagnosticCollector<JavaFileObject> diagnostics = new DiagnosticCollector<JavaFileObject>(); MemoryJavaFileManager fileManager = new ...
[ "public", "static", "Class", "compileClass", "(", "String", "name", ",", "String", "code", ",", "List", "<", "Class", ">", "classPath", ")", "throws", "Exception", "{", "JavaCompiler", "compiler", "=", "ToolProvider", ".", "getSystemJavaCompiler", "(", ")", ";...
Compiles Java code and returns compiled class back.
[ "Compiles", "Java", "code", "and", "returns", "compiled", "class", "back", "." ]
8a24db296dc43db5d8fe509cf64ace0a0c7be8f2
https://github.com/kirgor/enklib/blob/8a24db296dc43db5d8fe509cf64ace0a0c7be8f2/compile/src/main/java/com/kirgor/enklib/compile/CompileUtils.java#L20-L58
152,702
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java
ExternalTrxMessage.init
public void init(BaseMessage message, Object objRawMessage) { m_message = message; if (message != null) message.setExternalMessage(this); if (objRawMessage != null) this.setRawData(objRawMessage); }
java
public void init(BaseMessage message, Object objRawMessage) { m_message = message; if (message != null) message.setExternalMessage(this); if (objRawMessage != null) this.setRawData(objRawMessage); }
[ "public", "void", "init", "(", "BaseMessage", "message", ",", "Object", "objRawMessage", ")", "{", "m_message", "=", "message", ";", "if", "(", "message", "!=", "null", ")", "message", ".", "setExternalMessage", "(", "this", ")", ";", "if", "(", "objRawMes...
Initialize new ExternalTrxMessage. @param objRawMessage The (optional) raw data of the message.
[ "Initialize", "new", "ExternalTrxMessage", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java#L88-L95
152,703
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java
ExternalTrxMessage.moveHeaderParams
public void moveHeaderParams(Map<String,Object> mapMessage, Map<String,Object> mapHeader) { for (int i = 0; i < m_rgstrHeaderParams.length; i++) { if (mapMessage.get(m_rgstrHeaderParams[i]) != null) if (mapHeader.get(m_rgstrHeaderParams[i]) == null) { ...
java
public void moveHeaderParams(Map<String,Object> mapMessage, Map<String,Object> mapHeader) { for (int i = 0; i < m_rgstrHeaderParams.length; i++) { if (mapMessage.get(m_rgstrHeaderParams[i]) != null) if (mapHeader.get(m_rgstrHeaderParams[i]) == null) { ...
[ "public", "void", "moveHeaderParams", "(", "Map", "<", "String", ",", "Object", ">", "mapMessage", ",", "Map", "<", "String", ",", "Object", ">", "mapHeader", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "m_rgstrHeaderParams", ".", "lengt...
Move the header params from the message map to the header map.
[ "Move", "the", "header", "params", "from", "the", "message", "map", "to", "the", "header", "map", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java#L225-L237
152,704
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java
ExternalTrxMessage.getScratchDocument
public Document getScratchDocument(DocumentBuilder db) { if (m_doc == null) { m_doc = db.newDocument(); } return m_doc; }
java
public Document getScratchDocument(DocumentBuilder db) { if (m_doc == null) { m_doc = db.newDocument(); } return m_doc; }
[ "public", "Document", "getScratchDocument", "(", "DocumentBuilder", "db", ")", "{", "if", "(", "m_doc", "==", "null", ")", "{", "m_doc", "=", "db", ".", "newDocument", "(", ")", ";", "}", "return", "m_doc", ";", "}" ]
Get the scratch document for this message. Creates a new document the first time. @return The scratch document.
[ "Get", "the", "scratch", "document", "for", "this", "message", ".", "Creates", "a", "new", "document", "the", "first", "time", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java#L243-L250
152,705
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java
ExternalTrxMessage.getXSLTDocument
public String getXSLTDocument() { TrxMessageHeader messageHeader = (TrxMessageHeader)this.getMessage().getMessageHeader(); String strDocument = null; if (messageHeader != null) strDocument = (String)messageHeader.get(TrxMessageHeader.XSLT_DOCUMENT); return strDocument; ...
java
public String getXSLTDocument() { TrxMessageHeader messageHeader = (TrxMessageHeader)this.getMessage().getMessageHeader(); String strDocument = null; if (messageHeader != null) strDocument = (String)messageHeader.get(TrxMessageHeader.XSLT_DOCUMENT); return strDocument; ...
[ "public", "String", "getXSLTDocument", "(", ")", "{", "TrxMessageHeader", "messageHeader", "=", "(", "TrxMessageHeader", ")", "this", ".", "getMessage", "(", ")", ".", "getMessageHeader", "(", ")", ";", "String", "strDocument", "=", "null", ";", "if", "(", "...
Get the XSLT Document to do the conversion. Override this if you have a standard document to suppyl. @param source The source XML document. @return The XML tree that conforms to the ECXML format.
[ "Get", "the", "XSLT", "Document", "to", "do", "the", "conversion", ".", "Override", "this", "if", "you", "have", "a", "standard", "document", "to", "suppyl", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java#L307-L314
152,706
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java
ExternalTrxMessage.getTransformerStream
public StreamSource getTransformerStream(String strDocument) { StreamSource source = null; if (strDocument == null) strDocument = this.getXSLTDocument(); if (strDocument == null) { Reader reader = new StringReader(XSL_CONVERT); source = new StreamS...
java
public StreamSource getTransformerStream(String strDocument) { StreamSource source = null; if (strDocument == null) strDocument = this.getXSLTDocument(); if (strDocument == null) { Reader reader = new StringReader(XSL_CONVERT); source = new StreamS...
[ "public", "StreamSource", "getTransformerStream", "(", "String", "strDocument", ")", "{", "StreamSource", "source", "=", "null", ";", "if", "(", "strDocument", "==", "null", ")", "strDocument", "=", "this", ".", "getXSLTDocument", "(", ")", ";", "if", "(", "...
Get the XSLT transformer stream from this file or URL String. @param strDocument a URL or file string for the XSL document. @returns The transformer or default transformer if it doesn't exist.
[ "Get", "the", "XSLT", "transformer", "stream", "from", "this", "file", "or", "URL", "String", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/message/external/ExternalTrxMessage.java#L320-L379
152,707
carewebframework/carewebframework-vista
org.carewebframework.vista.api-parent/org.carewebframework.vista.api.patientlist/src/main/java/org/carewebframework/vista/patientlist/PatientList.java
PatientList.getListItems
@Override public Collection<PatientListItem> getListItems() { if (!noCaching && patients != null) { return patients; } patients = new ArrayList<>(); AbstractPatientListFilter filter = isFiltered() ? getActiveFilter() : null; PatientListFilterEntity entity...
java
@Override public Collection<PatientListItem> getListItems() { if (!noCaching && patients != null) { return patients; } patients = new ArrayList<>(); AbstractPatientListFilter filter = isFiltered() ? getActiveFilter() : null; PatientListFilterEntity entity...
[ "@", "Override", "public", "Collection", "<", "PatientListItem", ">", "getListItems", "(", ")", "{", "if", "(", "!", "noCaching", "&&", "patients", "!=", "null", ")", "{", "return", "patients", ";", "}", "patients", "=", "new", "ArrayList", "<>", "(", ")...
Returns the patient list. @return Patient list.
[ "Returns", "the", "patient", "list", "." ]
883b2cbe395d9e8a21cd19db820f0876bda6b1c6
https://github.com/carewebframework/carewebframework-vista/blob/883b2cbe395d9e8a21cd19db820f0876bda6b1c6/org.carewebframework.vista.api-parent/org.carewebframework.vista.api.patientlist/src/main/java/org/carewebframework/vista/patientlist/PatientList.java#L120-L133
152,708
tvesalainen/util
util/src/main/java/org/vesalainen/util/MapCollections.java
MapCollections.unmodifiableMapList
public static final <K,V> MapList<K,V> unmodifiableMapList(MapList<K,V> map) { return new UnmodifiableMapList(Collections.unmodifiableMap(map), map.getComparator()); }
java
public static final <K,V> MapList<K,V> unmodifiableMapList(MapList<K,V> map) { return new UnmodifiableMapList(Collections.unmodifiableMap(map), map.getComparator()); }
[ "public", "static", "final", "<", "K", ",", "V", ">", "MapList", "<", "K", ",", "V", ">", "unmodifiableMapList", "(", "MapList", "<", "K", ",", "V", ">", "map", ")", "{", "return", "new", "UnmodifiableMapList", "(", "Collections", ".", "unmodifiableMap",...
Returns unmodifiable MapList. @param <K> @param <V> @param map @return
[ "Returns", "unmodifiable", "MapList", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/MapCollections.java#L43-L46
152,709
tvesalainen/util
util/src/main/java/org/vesalainen/util/MapCollections.java
MapCollections.unmodifiableMapSet
public static final <K,V> MapSet<K,V> unmodifiableMapSet(MapSet<K,V> set) { return new UnmodifiableMapSet(set); }
java
public static final <K,V> MapSet<K,V> unmodifiableMapSet(MapSet<K,V> set) { return new UnmodifiableMapSet(set); }
[ "public", "static", "final", "<", "K", ",", "V", ">", "MapSet", "<", "K", ",", "V", ">", "unmodifiableMapSet", "(", "MapSet", "<", "K", ",", "V", ">", "set", ")", "{", "return", "new", "UnmodifiableMapSet", "(", "set", ")", ";", "}" ]
Returns unmodifiable MapSet. @param <K> @param <V> @param set @return
[ "Returns", "unmodifiable", "MapSet", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/MapCollections.java#L220-L223
152,710
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/KeyField.java
KeyField.free
public void free() { m_keyArea.removeKeyField(this); m_keyArea = null; m_field = null; if (m_fieldTempParam != null) m_fieldTempParam.free(); m_fieldTempParam = null; // BaseField if (m_fieldStartParam != null) m_fieldStartParam.free(); ...
java
public void free() { m_keyArea.removeKeyField(this); m_keyArea = null; m_field = null; if (m_fieldTempParam != null) m_fieldTempParam.free(); m_fieldTempParam = null; // BaseField if (m_fieldStartParam != null) m_fieldStartParam.free(); ...
[ "public", "void", "free", "(", ")", "{", "m_keyArea", ".", "removeKeyField", "(", "this", ")", ";", "m_keyArea", "=", "null", ";", "m_field", "=", "null", ";", "if", "(", "m_fieldTempParam", "!=", "null", ")", "m_fieldTempParam", ".", "free", "(", ")", ...
Free this key field.
[ "Free", "this", "key", "field", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/KeyField.java#L87-L101
152,711
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/KeyField.java
KeyField.getField
public BaseField getField(int iAreaDesc) { switch (iAreaDesc) { default: case DBConstants.FILE_KEY_AREA: return m_field; case DBConstants.TEMP_KEY_AREA: if (m_fieldTempParam == null) { try { m_fieldTemp...
java
public BaseField getField(int iAreaDesc) { switch (iAreaDesc) { default: case DBConstants.FILE_KEY_AREA: return m_field; case DBConstants.TEMP_KEY_AREA: if (m_fieldTempParam == null) { try { m_fieldTemp...
[ "public", "BaseField", "getField", "(", "int", "iAreaDesc", ")", "{", "switch", "(", "iAreaDesc", ")", "{", "default", ":", "case", "DBConstants", ".", "FILE_KEY_AREA", ":", "return", "m_field", ";", "case", "DBConstants", ".", "TEMP_KEY_AREA", ":", "if", "(...
Get the field that this KeyField points to. @param areaDesc KeyArea type File/Temp/Start/End. @return The field.
[ "Get", "the", "field", "that", "this", "KeyField", "points", "to", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/KeyField.java#L107-L151
152,712
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/entities/InjectionOptions.java
InjectionOptions.getInjectionSetting
private String getInjectionSetting(final String input, final char startDelim) { return input == null || input.equals("") ? null : StringUtilities.split(input, startDelim)[0].trim(); }
java
private String getInjectionSetting(final String input, final char startDelim) { return input == null || input.equals("") ? null : StringUtilities.split(input, startDelim)[0].trim(); }
[ "private", "String", "getInjectionSetting", "(", "final", "String", "input", ",", "final", "char", "startDelim", ")", "{", "return", "input", "==", "null", "||", "input", ".", "equals", "(", "\"\"", ")", "?", "null", ":", "StringUtilities", ".", "split", "...
Gets the Injection Setting for these options when using the String Constructor. @param input The input to be parsed to get the setting. @param startDelim The delimiter that specifies that start of options (ie '[') @return The title as a String or null if the title is blank.
[ "Gets", "the", "Injection", "Setting", "for", "these", "options", "when", "using", "the", "String", "Constructor", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/entities/InjectionOptions.java#L78-L80
152,713
eostermueller/headlessInTraceClient
src/main/java/org/headlessintrace/client/connection/DefaultConnection.java
DefaultConnection.removeCallback
public int removeCallback(IConnectionStateCallback criteria) { List<IConnectionStateCallback> listCallbacks = getConnectionDetail().getConnCallbacks(); /** * If this method is about to delete the last callback, then * there are no windows left listening, so it is safe to * do a hard disconne...
java
public int removeCallback(IConnectionStateCallback criteria) { List<IConnectionStateCallback> listCallbacks = getConnectionDetail().getConnCallbacks(); /** * If this method is about to delete the last callback, then * there are no windows left listening, so it is safe to * do a hard disconne...
[ "public", "int", "removeCallback", "(", "IConnectionStateCallback", "criteria", ")", "{", "List", "<", "IConnectionStateCallback", ">", "listCallbacks", "=", "getConnectionDetail", "(", ")", ".", "getConnCallbacks", "(", ")", ";", "/**\n\t\t * If this method is about to...
Returns the count of callbacks still listening to 'this'. This method will perform a hard disconnect if 0 is returned. @param criteria @return
[ "Returns", "the", "count", "of", "callbacks", "still", "listening", "to", "this", ".", "This", "method", "will", "perform", "a", "hard", "disconnect", "if", "0", "is", "returned", "." ]
50b1dccc5ff9e342c7c1d06b5a382e8c0afc7604
https://github.com/eostermueller/headlessInTraceClient/blob/50b1dccc5ff9e342c7c1d06b5a382e8c0afc7604/src/main/java/org/headlessintrace/client/connection/DefaultConnection.java#L233-L255
152,714
attribyte/wpdb
src/main/java/org/attribyte/wp/model/Site.java
Site.overrideWith
public Site overrideWith(final Site other) { return new Site( other.id > 0L ? other.id : this.id, other.baseURL != null ? other.baseURL : this.baseURL, other.title != null ? other.title : this.title, other.description != null ? other.description : this.descr...
java
public Site overrideWith(final Site other) { return new Site( other.id > 0L ? other.id : this.id, other.baseURL != null ? other.baseURL : this.baseURL, other.title != null ? other.title : this.title, other.description != null ? other.description : this.descr...
[ "public", "Site", "overrideWith", "(", "final", "Site", "other", ")", "{", "return", "new", "Site", "(", "other", ".", "id", ">", "0L", "?", "other", ".", "id", ":", "this", ".", "id", ",", "other", ".", "baseURL", "!=", "null", "?", "other", ".", ...
Overrides values in this site with those in another, if set. @param other The other site meta. @return The site meta with overrides applied.
[ "Overrides", "values", "in", "this", "site", "with", "those", "in", "another", "if", "set", "." ]
b9adf6131dfb67899ebff770c9bfeb001cc42f30
https://github.com/attribyte/wpdb/blob/b9adf6131dfb67899ebff770c9bfeb001cc42f30/src/main/java/org/attribyte/wp/model/Site.java#L72-L81
152,715
attribyte/wpdb
src/main/java/org/attribyte/wp/model/Site.java
Site.buildPermalink
public String buildPermalink(final Post post) { final String authorSlug = post.author != null ? Strings.nullToEmpty(post.author.slug) : ""; final List<TaxonomyTerm> categories = post.categories(); final Term categoryTerm = categories.size() > 0 ? categories.get(0).term : defaultCategory; final ...
java
public String buildPermalink(final Post post) { final String authorSlug = post.author != null ? Strings.nullToEmpty(post.author.slug) : ""; final List<TaxonomyTerm> categories = post.categories(); final Term categoryTerm = categories.size() > 0 ? categories.get(0).term : defaultCategory; final ...
[ "public", "String", "buildPermalink", "(", "final", "Post", "post", ")", "{", "final", "String", "authorSlug", "=", "post", ".", "author", "!=", "null", "?", "Strings", ".", "nullToEmpty", "(", "post", ".", "author", ".", "slug", ")", ":", "\"\"", ";", ...
Builds the permalink for a post from this site. @param post The post. @return The permalink string. @see <a href="https://codex.wordpress.org/Using_Permalinks">https://codex.wordpress.org/Using_Permalinks</a>
[ "Builds", "the", "permalink", "for", "a", "post", "from", "this", "site", "." ]
b9adf6131dfb67899ebff770c9bfeb001cc42f30
https://github.com/attribyte/wpdb/blob/b9adf6131dfb67899ebff770c9bfeb001cc42f30/src/main/java/org/attribyte/wp/model/Site.java#L154-L180
152,716
jbundle/jbundle
thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java
JBlinkLabel.init
public void init(Object obj) { for (int i = 0; i < MAX_ICONS; i++) { ImageIcon icon = this.getImageIcon(i); if (icon == null) break; this.addIcon(icon, i); } }
java
public void init(Object obj) { for (int i = 0; i < MAX_ICONS; i++) { ImageIcon icon = this.getImageIcon(i); if (icon == null) break; this.addIcon(icon, i); } }
[ "public", "void", "init", "(", "Object", "obj", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "MAX_ICONS", ";", "i", "++", ")", "{", "ImageIcon", "icon", "=", "this", ".", "getImageIcon", "(", "i", ")", ";", "if", "(", "icon", "=="...
Creates new JBlinkLabel. @param obj Undefined.
[ "Creates", "new", "JBlinkLabel", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java#L100-L109
152,717
jbundle/jbundle
thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java
JBlinkLabel.getTableCellRendererComponent
public java.awt.Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) { if (m_table == null) { // Cache this for later. m_table = table; // The following code is here because the column of this compone...
java
public java.awt.Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) { if (m_table == null) { // Cache this for later. m_table = table; // The following code is here because the column of this compone...
[ "public", "java", ".", "awt", ".", "Component", "getTableCellRendererComponent", "(", "JTable", "table", ",", "Object", "value", ",", "boolean", "isSelected", ",", "boolean", "hasFocus", ",", "int", "row", ",", "int", "column", ")", "{", "if", "(", "m_table"...
If this control is in a JTable, this is how to render it. @param table The table this component is in. @param value The value of this cell. @param isSelected True if selected. @param hasFocus True if focused. @param row The table row. @param column The table column. @return This component (after updating for blink).
[ "If", "this", "control", "is", "in", "a", "JTable", "this", "is", "how", "to", "render", "it", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java#L128-L147
152,718
jbundle/jbundle
thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java
JBlinkLabel.getImageIcon
public ImageIcon getImageIcon(Object value) { if (value == null) return m_rgIcons[0]; String strType = value.toString(); int iType = 0; try { iType = Integer.parseInt(strType); } catch (NumberFormatException ex) { } if (m_rgIcons ==...
java
public ImageIcon getImageIcon(Object value) { if (value == null) return m_rgIcons[0]; String strType = value.toString(); int iType = 0; try { iType = Integer.parseInt(strType); } catch (NumberFormatException ex) { } if (m_rgIcons ==...
[ "public", "ImageIcon", "getImageIcon", "(", "Object", "value", ")", "{", "if", "(", "value", "==", "null", ")", "return", "m_rgIcons", "[", "0", "]", ";", "String", "strType", "=", "value", ".", "toString", "(", ")", ";", "int", "iType", "=", "0", ";...
Here is the value of this object, display the correct image. @return The appropriate image.
[ "Here", "is", "the", "value", "of", "this", "object", "display", "the", "correct", "image", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java#L152-L202
152,719
jbundle/jbundle
thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java
JBlinkLabel.addIcon
public void addIcon(Object icon, int iIndex) { if (m_rgIcons == null) { m_rgIcons = new ImageIcon[MAX_ICONS]; m_timer = new javax.swing.Timer(500, this); // Remind me to change graphics every 1/2 second m_timer.start(); } if (iIndex < MAX_I...
java
public void addIcon(Object icon, int iIndex) { if (m_rgIcons == null) { m_rgIcons = new ImageIcon[MAX_ICONS]; m_timer = new javax.swing.Timer(500, this); // Remind me to change graphics every 1/2 second m_timer.start(); } if (iIndex < MAX_I...
[ "public", "void", "addIcon", "(", "Object", "icon", ",", "int", "iIndex", ")", "{", "if", "(", "m_rgIcons", "==", "null", ")", "{", "m_rgIcons", "=", "new", "ImageIcon", "[", "MAX_ICONS", "]", ";", "m_timer", "=", "new", "javax", ".", "swing", ".", "...
Add this icon to the list of icons alternating for this label. @param icon The icon to add. @param iIndex The index for this icon.
[ "Add", "this", "icon", "to", "the", "list", "of", "icons", "alternating", "for", "this", "label", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/JBlinkLabel.java#L208-L219
152,720
tvesalainen/util
util/src/main/java/org/vesalainen/bean/AbstractBeanField.java
AbstractBeanField.set
@Override public void set(Object value) { try { Object v = ConvertUtility.convert(type, value); if (field != null) { field.set(getBase(), v); } else { setter.invoke(getBase(), v); ...
java
@Override public void set(Object value) { try { Object v = ConvertUtility.convert(type, value); if (field != null) { field.set(getBase(), v); } else { setter.invoke(getBase(), v); ...
[ "@", "Override", "public", "void", "set", "(", "Object", "value", ")", "{", "try", "{", "Object", "v", "=", "ConvertUtility", ".", "convert", "(", "type", ",", "value", ")", ";", "if", "(", "field", "!=", "null", ")", "{", "field", ".", "set", "(",...
Set value using type conversions @param value @see org.vesalainen.util.ConvertUtility#convert(java.lang.Class, java.lang.Object)
[ "Set", "value", "using", "type", "conversions" ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/bean/AbstractBeanField.java#L93-L112
152,721
carewebframework/carewebframework-vista
org.carewebframework.vista.plugin-parent/org.carewebframework.vista.plugin.documents/src/main/java/org/carewebframework/vista/plugin/documents/DocumentDisplayComboRenderer.java
DocumentDisplayComboRenderer.renderItem
@Override public void renderItem(final Comboitem item, final Document doc) { item.setLabel(doc.getTitle()); }
java
@Override public void renderItem(final Comboitem item, final Document doc) { item.setLabel(doc.getTitle()); }
[ "@", "Override", "public", "void", "renderItem", "(", "final", "Comboitem", "item", ",", "final", "Document", "doc", ")", "{", "item", ".", "setLabel", "(", "doc", ".", "getTitle", "(", ")", ")", ";", "}" ]
Render the combo item for the specified document. @param item Combo item to render. @param doc The document associated with the list item.
[ "Render", "the", "combo", "item", "for", "the", "specified", "document", "." ]
883b2cbe395d9e8a21cd19db820f0876bda6b1c6
https://github.com/carewebframework/carewebframework-vista/blob/883b2cbe395d9e8a21cd19db820f0876bda6b1c6/org.carewebframework.vista.plugin-parent/org.carewebframework.vista.plugin.documents/src/main/java/org/carewebframework/vista/plugin/documents/DocumentDisplayComboRenderer.java#L44-L47
152,722
jbundle/jbundle
app/program/script/src/main/java/org/jbundle/app/program/script/scan/XslRepositoryScanListener.java
XslRepositoryScanListener.readFile
public String readFile(String filename) { String path = m_fileSource.getParent(); String string = Utility.transferURLStream("file:" + path + '/' + filename, null, null, null); if (string != null) { int start = string.indexOf("<repository"); if (start != -1) ...
java
public String readFile(String filename) { String path = m_fileSource.getParent(); String string = Utility.transferURLStream("file:" + path + '/' + filename, null, null, null); if (string != null) { int start = string.indexOf("<repository"); if (start != -1) ...
[ "public", "String", "readFile", "(", "String", "filename", ")", "{", "String", "path", "=", "m_fileSource", ".", "getParent", "(", ")", ";", "String", "string", "=", "Utility", ".", "transferURLStream", "(", "\"file:\"", "+", "path", "+", "'", "'", "+", ...
ReadFile Method.
[ "ReadFile", "Method", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/app/program/script/src/main/java/org/jbundle/app/program/script/scan/XslRepositoryScanListener.java#L78-L92
152,723
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByAbsolutePath
public static boolean compareFilesByAbsolutePath(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, false, true, true, true, true, true) .getAbsolutePathEquality(); }
java
public static boolean compareFilesByAbsolutePath(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, false, true, true, true, true, true) .getAbsolutePathEquality(); }
[ "public", "static", "boolean", "compareFilesByAbsolutePath", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "{", "return", "CompareFileExtensions", ".", "compareFiles", "(", "sourceFile", ",", "fileToCompare", ",", "false", ",", "tru...
Compare files by absolute path. @param sourceFile the source file @param fileToCompare the file to compare @return true if the absolute path are equal, otherwise false.
[ "Compare", "files", "by", "absolute", "path", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L51-L57
152,724
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByChecksumCRC32
public static boolean compareFilesByChecksumCRC32(final File sourceFile, final File fileToCompare) throws IOException { final long checksumSourceFile = ChecksumExtensions.getCheckSumCRC32(sourceFile); final long checksumFileToCompare = ChecksumExtensions.getCheckSumCRC32(fileToCompare); return checksumSourceFi...
java
public static boolean compareFilesByChecksumCRC32(final File sourceFile, final File fileToCompare) throws IOException { final long checksumSourceFile = ChecksumExtensions.getCheckSumCRC32(sourceFile); final long checksumFileToCompare = ChecksumExtensions.getCheckSumCRC32(fileToCompare); return checksumSourceFi...
[ "public", "static", "boolean", "compareFilesByChecksumCRC32", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "throws", "IOException", "{", "final", "long", "checksumSourceFile", "=", "ChecksumExtensions", ".", "getCheckSumCRC32", "(", ...
Compare files by checksum with the algorithm CRC32. @param sourceFile the source file @param fileToCompare the file to compare @return true if the checksum with the algorithm CRC32 are equal, otherwise false. @throws IOException Signals that an I/O exception has occurred.
[ "Compare", "files", "by", "checksum", "with", "the", "algorithm", "CRC32", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L113-L119
152,725
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByContent
public static boolean compareFilesByContent(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, true, true, true, false) .getContentEquality(); }
java
public static boolean compareFilesByContent(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, true, true, true, false) .getContentEquality(); }
[ "public", "static", "boolean", "compareFilesByContent", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "{", "return", "CompareFileExtensions", ".", "compareFiles", "(", "sourceFile", ",", "fileToCompare", ",", "true", ",", "true", ...
Compare files by content. @param sourceFile the source file @param fileToCompare the file to compare @return true if the content are equal, otherwise false.
[ "Compare", "files", "by", "content", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L131-L136
152,726
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByExtension
public static boolean compareFilesByExtension(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, false, true, true, true, true) .getFileExtensionEquality(); }
java
public static boolean compareFilesByExtension(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, false, true, true, true, true) .getFileExtensionEquality(); }
[ "public", "static", "boolean", "compareFilesByExtension", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "{", "return", "CompareFileExtensions", ".", "compareFiles", "(", "sourceFile", ",", "fileToCompare", ",", "true", ",", "false",...
Compare files by extension. @param sourceFile the source file @param fileToCompare the file to compare @return true if the extension are equal, otherwise false.
[ "Compare", "files", "by", "extension", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L147-L152
152,727
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByLastModified
public static boolean compareFilesByLastModified(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, true, false, true, true) .getLastModifiedEquality(); }
java
public static boolean compareFilesByLastModified(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, true, false, true, true) .getLastModifiedEquality(); }
[ "public", "static", "boolean", "compareFilesByLastModified", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "{", "return", "CompareFileExtensions", ".", "compareFiles", "(", "sourceFile", ",", "fileToCompare", ",", "true", ",", "true...
Compare files by last modified. @param sourceFile the source file @param fileToCompare the file to compare @return true if the last modified are equal, otherwise false.
[ "Compare", "files", "by", "last", "modified", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L163-L169
152,728
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByLength
public static boolean compareFilesByLength(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, false, true, true, true) .getLengthEquality(); }
java
public static boolean compareFilesByLength(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, false, true, true, true) .getLengthEquality(); }
[ "public", "static", "boolean", "compareFilesByLength", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "{", "return", "CompareFileExtensions", ".", "compareFiles", "(", "sourceFile", ",", "fileToCompare", ",", "true", ",", "true", "...
Compare files by length. @param sourceFile the source file @param fileToCompare the file to compare @return true if the length are equal, otherwise false.
[ "Compare", "files", "by", "length", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L180-L185
152,729
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java
SimpleCompareFileExtensions.compareFilesByName
public static boolean compareFilesByName(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, true, true, false, true) .getNameEquality(); }
java
public static boolean compareFilesByName(final File sourceFile, final File fileToCompare) { return CompareFileExtensions .compareFiles(sourceFile, fileToCompare, true, true, true, true, false, true) .getNameEquality(); }
[ "public", "static", "boolean", "compareFilesByName", "(", "final", "File", "sourceFile", ",", "final", "File", "fileToCompare", ")", "{", "return", "CompareFileExtensions", ".", "compareFiles", "(", "sourceFile", ",", "fileToCompare", ",", "true", ",", "true", ","...
Compare files by name. @param sourceFile the source file @param fileToCompare the file to compare @return true if the name are equal, otherwise false.
[ "Compare", "files", "by", "name", "." ]
2c81de10fb5d68de64c1abc3ed64ca681ce76da8
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/compare/SimpleCompareFileExtensions.java#L196-L201
152,730
hdecarne/java-default
src/main/java/de/carne/util/function/FunctionException.java
FunctionException.rethrow
public <T extends Exception> T rethrow(Class<T> exceptionType) { return exceptionType.cast(getCause()); }
java
public <T extends Exception> T rethrow(Class<T> exceptionType) { return exceptionType.cast(getCause()); }
[ "public", "<", "T", "extends", "Exception", ">", "T", "rethrow", "(", "Class", "<", "T", ">", "exceptionType", ")", "{", "return", "exceptionType", ".", "cast", "(", "getCause", "(", ")", ")", ";", "}" ]
Get the wrapped exception for re-throwing. @param <T> The wrapped excption's type. @param exceptionType The wrapped exception type. @return The wrapped exception.
[ "Get", "the", "wrapped", "exception", "for", "re", "-", "throwing", "." ]
ca16f6fdb0436e90e9e2df3106055e320bb3c9e3
https://github.com/hdecarne/java-default/blob/ca16f6fdb0436e90e9e2df3106055e320bb3c9e3/src/main/java/de/carne/util/function/FunctionException.java#L42-L44
152,731
jbundle/jbundle
thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/SwingPortableImageUtil.java
SwingPortableImageUtil.getTracker
private MediaTracker getTracker() { // Opt: Only synchronize if trackerObj comes back null? // If null, synchronize, re-check for null, and put new tracker synchronized(this) { if (tracker == null) { @SuppressWarnings("serial") Component comp = new Com...
java
private MediaTracker getTracker() { // Opt: Only synchronize if trackerObj comes back null? // If null, synchronize, re-check for null, and put new tracker synchronized(this) { if (tracker == null) { @SuppressWarnings("serial") Component comp = new Com...
[ "private", "MediaTracker", "getTracker", "(", ")", "{", "// Opt: Only synchronize if trackerObj comes back null?", "// If null, synchronize, re-check for null, and put new tracker", "synchronized", "(", "this", ")", "{", "if", "(", "tracker", "==", "null", ")", "{", "@", "S...
Returns the MediaTracker for the current AppContext, creating a new MediaTracker if necessary.
[ "Returns", "the", "MediaTracker", "for", "the", "current", "AppContext", "creating", "a", "new", "MediaTracker", "if", "necessary", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/screen/util/src/main/java/org/jbundle/thin/base/screen/util/SwingPortableImageUtil.java#L144-L155
152,732
the-fascinator/plugin-indexer-solr
src/main/java/com/googlecode/fascinator/indexer/rules/AddField.java
AddField.run
@Override public void run(Reader in, Writer out) throws RuleException { //log("Adding field [" + field + "]"); try { AddDoc addDoc = AddDoc.read(in); addDoc.getFields().add(field); addDoc.write(out); } catch (JAXBException jaxbe) { throw new Ru...
java
@Override public void run(Reader in, Writer out) throws RuleException { //log("Adding field [" + field + "]"); try { AddDoc addDoc = AddDoc.read(in); addDoc.getFields().add(field); addDoc.write(out); } catch (JAXBException jaxbe) { throw new Ru...
[ "@", "Override", "public", "void", "run", "(", "Reader", "in", ",", "Writer", "out", ")", "throws", "RuleException", "{", "//log(\"Adding field [\" + field + \"]\");", "try", "{", "AddDoc", "addDoc", "=", "AddDoc", ".", "read", "(", "in", ")", ";", "addDoc", ...
Adds a single field to a Solr document @param in Solr document @param out Solr document with added field
[ "Adds", "a", "single", "field", "to", "a", "Solr", "document" ]
001159b18b78a87daa5d8b2a17ced28694bae156
https://github.com/the-fascinator/plugin-indexer-solr/blob/001159b18b78a87daa5d8b2a17ced28694bae156/src/main/java/com/googlecode/fascinator/indexer/rules/AddField.java#L76-L86
152,733
js-lib-com/commons
src/main/java/js/io/FilesIterator.java
FilesIterator.getRelativeNamesIterator
public static FilesIterator<String> getRelativeNamesIterator(File baseDir) { return new FilesIterator<String>(baseDir, Strategy.RELATIVE_NAMES); }
java
public static FilesIterator<String> getRelativeNamesIterator(File baseDir) { return new FilesIterator<String>(baseDir, Strategy.RELATIVE_NAMES); }
[ "public", "static", "FilesIterator", "<", "String", ">", "getRelativeNamesIterator", "(", "File", "baseDir", ")", "{", "return", "new", "FilesIterator", "<", "String", ">", "(", "baseDir", ",", "Strategy", ".", "RELATIVE_NAMES", ")", ";", "}" ]
Create relative file names iterator. @param baseDir base directory to scan for files. @return files iterator.
[ "Create", "relative", "file", "names", "iterator", "." ]
f8c64482142b163487745da74feb106f0765c16b
https://github.com/js-lib-com/commons/blob/f8c64482142b163487745da74feb106f0765c16b/src/main/java/js/io/FilesIterator.java#L95-L97
152,734
js-lib-com/commons
src/main/java/js/io/FilesIterator.java
FilesIterator.getAbsoluteIterator
public static FilesIterator<File> getAbsoluteIterator(String baseDir) { return new FilesIterator<File>(new File(baseDir), Strategy.FILES); }
java
public static FilesIterator<File> getAbsoluteIterator(String baseDir) { return new FilesIterator<File>(new File(baseDir), Strategy.FILES); }
[ "public", "static", "FilesIterator", "<", "File", ">", "getAbsoluteIterator", "(", "String", "baseDir", ")", "{", "return", "new", "FilesIterator", "<", "File", ">", "(", "new", "File", "(", "baseDir", ")", ",", "Strategy", ".", "FILES", ")", ";", "}" ]
Create absolute path files iterator. @param baseDir base directory path to scan for files. @return files iterator.
[ "Create", "absolute", "path", "files", "iterator", "." ]
f8c64482142b163487745da74feb106f0765c16b
https://github.com/js-lib-com/commons/blob/f8c64482142b163487745da74feb106f0765c16b/src/main/java/js/io/FilesIterator.java#L105-L107
152,735
js-lib-com/commons
src/main/java/js/io/FilesIterator.java
FilesIterator.getRelativeIterator
public static FilesIterator<File> getRelativeIterator(String baseDir) { return new FilesIterator<File>(new File(baseDir), Strategy.RELATIVE_FILES); }
java
public static FilesIterator<File> getRelativeIterator(String baseDir) { return new FilesIterator<File>(new File(baseDir), Strategy.RELATIVE_FILES); }
[ "public", "static", "FilesIterator", "<", "File", ">", "getRelativeIterator", "(", "String", "baseDir", ")", "{", "return", "new", "FilesIterator", "<", "File", ">", "(", "new", "File", "(", "baseDir", ")", ",", "Strategy", ".", "RELATIVE_FILES", ")", ";", ...
Create relative path files iterator. @param baseDir base directory path to scan for files. @return files iterator.
[ "Create", "relative", "path", "files", "iterator", "." ]
f8c64482142b163487745da74feb106f0765c16b
https://github.com/js-lib-com/commons/blob/f8c64482142b163487745da74feb106f0765c16b/src/main/java/js/io/FilesIterator.java#L115-L117
152,736
js-lib-com/commons
src/main/java/js/io/FilesIterator.java
FilesIterator.getAbsoluteNamesIterator
public static FilesIterator<String> getAbsoluteNamesIterator(String baseDir) { return new FilesIterator<String>(new File(baseDir), Strategy.NAMES); }
java
public static FilesIterator<String> getAbsoluteNamesIterator(String baseDir) { return new FilesIterator<String>(new File(baseDir), Strategy.NAMES); }
[ "public", "static", "FilesIterator", "<", "String", ">", "getAbsoluteNamesIterator", "(", "String", "baseDir", ")", "{", "return", "new", "FilesIterator", "<", "String", ">", "(", "new", "File", "(", "baseDir", ")", ",", "Strategy", ".", "NAMES", ")", ";", ...
Create absolute file names iterator. @param baseDir base directory name to scan for files. @return files iterator.
[ "Create", "absolute", "file", "names", "iterator", "." ]
f8c64482142b163487745da74feb106f0765c16b
https://github.com/js-lib-com/commons/blob/f8c64482142b163487745da74feb106f0765c16b/src/main/java/js/io/FilesIterator.java#L125-L127
152,737
js-lib-com/commons
src/main/java/js/io/FilesIterator.java
FilesIterator.isLoopExitCondition
private boolean isLoopExitCondition() { while (workingDirectory.index == workingDirectory.files.length) { if (stack.isEmpty()) { return true; } pop(); } return false; }
java
private boolean isLoopExitCondition() { while (workingDirectory.index == workingDirectory.files.length) { if (stack.isEmpty()) { return true; } pop(); } return false; }
[ "private", "boolean", "isLoopExitCondition", "(", ")", "{", "while", "(", "workingDirectory", ".", "index", "==", "workingDirectory", ".", "files", ".", "length", ")", "{", "if", "(", "stack", ".", "isEmpty", "(", ")", ")", "{", "return", "true", ";", "}...
Test for iteration loop exit condition. Iteration loop is ended if current working directory index reaches its files count and there is no more directories on stack. @return true if iterator loop reach its end.
[ "Test", "for", "iteration", "loop", "exit", "condition", ".", "Iteration", "loop", "is", "ended", "if", "current", "working", "directory", "index", "reaches", "its", "files", "count", "and", "there", "is", "no", "more", "directories", "on", "stack", "." ]
f8c64482142b163487745da74feb106f0765c16b
https://github.com/js-lib-com/commons/blob/f8c64482142b163487745da74feb106f0765c16b/src/main/java/js/io/FilesIterator.java#L247-L255
152,738
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/event/OnSelectHandler.java
OnSelectHandler.init
public void init(Record record, RecordOwner recordOwner, Record recordToSync, boolean bUpdateOnSelect, int iEventToTrigger) { super.init(record); m_recordOwner = recordOwner; m_recordToSync = recordToSync; m_bUpdateOnSelect = bUpdateOnSelect; m_iEventToTrigger = iEventToTrigg...
java
public void init(Record record, RecordOwner recordOwner, Record recordToSync, boolean bUpdateOnSelect, int iEventToTrigger) { super.init(record); m_recordOwner = recordOwner; m_recordToSync = recordToSync; m_bUpdateOnSelect = bUpdateOnSelect; m_iEventToTrigger = iEventToTrigg...
[ "public", "void", "init", "(", "Record", "record", ",", "RecordOwner", "recordOwner", ",", "Record", "recordToSync", ",", "boolean", "bUpdateOnSelect", ",", "int", "iEventToTrigger", ")", "{", "super", ".", "init", "(", "record", ")", ";", "m_recordOwner", "="...
OnSelectHandler - Constructor. @param record My owner (usually passed as null, and set on addListener in setOwner()). @param recordToSync The record to synchronize with this one. @param bUpdateOnSelect If true, update or add a record in progress before syncing this record.
[ "OnSelectHandler", "-", "Constructor", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/event/OnSelectHandler.java#L102-L109
152,739
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/event/OnSelectHandler.java
OnSelectHandler.setOwner
public void setOwner(ListenerOwner owner) { super.setOwner(owner); if (owner != null) if (m_recordToSync != null) { if (!m_recordToSync.getBaseRecord().getTableNames(false).equals(this.getOwner().getBaseRecord().getTableNames(false))) { // Must be the same base tabl...
java
public void setOwner(ListenerOwner owner) { super.setOwner(owner); if (owner != null) if (m_recordToSync != null) { if (!m_recordToSync.getBaseRecord().getTableNames(false).equals(this.getOwner().getBaseRecord().getTableNames(false))) { // Must be the same base tabl...
[ "public", "void", "setOwner", "(", "ListenerOwner", "owner", ")", "{", "super", ".", "setOwner", "(", "owner", ")", ";", "if", "(", "owner", "!=", "null", ")", "if", "(", "m_recordToSync", "!=", "null", ")", "{", "if", "(", "!", "m_recordToSync", ".", ...
Set the field or file that owns this listener. I Check to make sure that the base tables are the same first. @param owner My owner.
[ "Set", "the", "field", "or", "file", "that", "owns", "this", "listener", ".", "I", "Check", "to", "make", "sure", "that", "the", "base", "tables", "are", "the", "same", "first", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/event/OnSelectHandler.java#L115-L127
152,740
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/event/OnSelectHandler.java
OnSelectHandler.createMessage
public RecordMessage createMessage(Object bookmark) { int iRecordMessageType = DBConstants.SELECT_TYPE; RecordMessageHeader messageHeader = new RecordMessageHeader(this.getOwner(), bookmark, null, iRecordMessageType, null); RecordMessage message = new RecordMessage(messageHeader); me...
java
public RecordMessage createMessage(Object bookmark) { int iRecordMessageType = DBConstants.SELECT_TYPE; RecordMessageHeader messageHeader = new RecordMessageHeader(this.getOwner(), bookmark, null, iRecordMessageType, null); RecordMessage message = new RecordMessage(messageHeader); me...
[ "public", "RecordMessage", "createMessage", "(", "Object", "bookmark", ")", "{", "int", "iRecordMessageType", "=", "DBConstants", ".", "SELECT_TYPE", ";", "RecordMessageHeader", "messageHeader", "=", "new", "RecordMessageHeader", "(", "this", ".", "getOwner", "(", "...
Create the record message. Override this to add information to the message. @param bookmark The bookmark of the record that is selected. @return The record message.
[ "Create", "the", "record", "message", ".", "Override", "this", "to", "add", "information", "to", "the", "message", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/event/OnSelectHandler.java#L181-L190
152,741
jbundle/jbundle
base/message/service/src/main/java/org/jbundle/base/message/service/BaseMessageServiceActivator.java
BaseMessageServiceActivator.shutdownService
public boolean shutdownService(Object service, BundleContext context) { if (service instanceof BaseServiceMessageTransport) // Always ((BaseServiceMessageTransport)service).free(); return super.shutdownService(service, context); }
java
public boolean shutdownService(Object service, BundleContext context) { if (service instanceof BaseServiceMessageTransport) // Always ((BaseServiceMessageTransport)service).free(); return super.shutdownService(service, context); }
[ "public", "boolean", "shutdownService", "(", "Object", "service", ",", "BundleContext", "context", ")", "{", "if", "(", "service", "instanceof", "BaseServiceMessageTransport", ")", "// Always", "(", "(", "BaseServiceMessageTransport", ")", "service", ")", ".", "free...
Stop this service. Override this to do all the startup. @param bundleService @param context bundle context @return true if successful.
[ "Stop", "this", "service", ".", "Override", "this", "to", "do", "all", "the", "startup", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/service/src/main/java/org/jbundle/base/message/service/BaseMessageServiceActivator.java#L113-L118
152,742
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.fork
public void fork(K to, M msg) { if (maxParallelism == 0) { throw new IllegalArgumentException("maxParallelism == 0, fork() not allowed! Use switchTo."); } try { stopSemaphore.acquire(); parallelSet.add(getCurrentKey()); ...
java
public void fork(K to, M msg) { if (maxParallelism == 0) { throw new IllegalArgumentException("maxParallelism == 0, fork() not allowed! Use switchTo."); } try { stopSemaphore.acquire(); parallelSet.add(getCurrentKey()); ...
[ "public", "void", "fork", "(", "K", "to", ",", "M", "msg", ")", "{", "if", "(", "maxParallelism", "==", "0", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"maxParallelism == 0, fork() not allowed! Use switchTo.\"", ")", ";", "}", "try", "{", "st...
Fork executing thread. @param to Next executing @param msg Message to
[ "Fork", "executing", "thread", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L118-L134
152,743
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.join
public M join() { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } Thread currentThread = Thread.currentThread(); Semaphore currentSemaphore = semaphoreMap.get(currentThread); if (currentSemaphore == ...
java
public M join() { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } Thread currentThread = Thread.currentThread(); Semaphore currentSemaphore = semaphoreMap.get(currentThread); if (currentSemaphore == ...
[ "public", "M", "join", "(", ")", "{", "if", "(", "threadMap", ".", "isEmpty", "(", ")", ")", "{", "throw", "new", "IllegalStateException", "(", "\"threads are already interrupted\"", ")", ";", "}", "Thread", "currentThread", "=", "Thread", ".", "currentThread"...
Thread waits until another thread calls fork, switchTo or endTo method using threads key. Returns message from another thread. @return
[ "Thread", "waits", "until", "another", "thread", "calls", "fork", "switchTo", "or", "endTo", "method", "using", "threads", "key", ".", "Returns", "message", "from", "another", "thread", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L172-L187
152,744
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.switchTo
public M switchTo(K to, M msg) { doFork(to, msg); return doJoin(); }
java
public M switchTo(K to, M msg) { doFork(to, msg); return doJoin(); }
[ "public", "M", "switchTo", "(", "K", "to", ",", "M", "msg", ")", "{", "doFork", "(", "to", ",", "msg", ")", ";", "return", "doJoin", "(", ")", ";", "}" ]
Switch executing thread. @param to Next executing @param msg @return
[ "Switch", "executing", "thread", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L254-L258
152,745
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.endTo
public void endTo(K to, M msg) { K key = getCurrentKey(); if (key.equals(to)) { throw new IllegalArgumentException("current and to are equals"); } if (key != null) { kill(key); doFork(to, msg); throw new Threa...
java
public void endTo(K to, M msg) { K key = getCurrentKey(); if (key.equals(to)) { throw new IllegalArgumentException("current and to are equals"); } if (key != null) { kill(key); doFork(to, msg); throw new Threa...
[ "public", "void", "endTo", "(", "K", "to", ",", "M", "msg", ")", "{", "K", "key", "=", "getCurrentKey", "(", ")", ";", "if", "(", "key", ".", "equals", "(", "to", ")", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"current and to are equ...
Ends the current thread and switches to @param to @param msg
[ "Ends", "the", "current", "thread", "and", "switches", "to" ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L281-L298
152,746
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.getCurrentKey
public K getCurrentKey() { lock.lock(); try { Thread currentThread = Thread.currentThread(); for (Entry<K,Thread> entry : threadMap.entrySet()) { if (currentThread.equals(entry.getValue())) { re...
java
public K getCurrentKey() { lock.lock(); try { Thread currentThread = Thread.currentThread(); for (Entry<K,Thread> entry : threadMap.entrySet()) { if (currentThread.equals(entry.getValue())) { re...
[ "public", "K", "getCurrentKey", "(", ")", "{", "lock", ".", "lock", "(", ")", ";", "try", "{", "Thread", "currentThread", "=", "Thread", ".", "currentThread", "(", ")", ";", "for", "(", "Entry", "<", "K", ",", "Thread", ">", "entry", ":", "threadMap"...
Returns key for current thread. Returns null if current thread is not part of the workflow. @return
[ "Returns", "key", "for", "current", "thread", ".", "Returns", "null", "if", "current", "thread", "is", "not", "part", "of", "the", "workflow", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L304-L323
152,747
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.waitAndStopThreads
public void waitAndStopThreads() { try { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } stopSemaphore.acquire(maxParallelism); stopThreads(); } cat...
java
public void waitAndStopThreads() { try { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } stopSemaphore.acquire(maxParallelism); stopThreads(); } cat...
[ "public", "void", "waitAndStopThreads", "(", ")", "{", "try", "{", "if", "(", "threadMap", ".", "isEmpty", "(", ")", ")", "{", "throw", "new", "IllegalStateException", "(", "\"threads are already interrupted\"", ")", ";", "}", "stopSemaphore", ".", "acquire", ...
Wait until parallel excecuting threads have joined. After that interrupt all other than the calling thread.
[ "Wait", "until", "parallel", "excecuting", "threads", "have", "joined", ".", "After", "that", "interrupt", "all", "other", "than", "the", "calling", "thread", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L352-L367
152,748
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.stopThreads
public void stopThreads() { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } lock.lock(); try { Thread currentThread = Thread.currentThread(); for (Thread thread : threadMap....
java
public void stopThreads() { if (threadMap.isEmpty()) { throw new IllegalStateException("threads are already interrupted"); } lock.lock(); try { Thread currentThread = Thread.currentThread(); for (Thread thread : threadMap....
[ "public", "void", "stopThreads", "(", ")", "{", "if", "(", "threadMap", ".", "isEmpty", "(", ")", ")", "{", "throw", "new", "IllegalStateException", "(", "\"threads are already interrupted\"", ")", ";", "}", "lock", ".", "lock", "(", ")", ";", "try", "{", ...
Interrupt all other than the calling thread.
[ "Interrupt", "all", "other", "than", "the", "calling", "thread", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L372-L396
152,749
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java
SimpleWorkflow.accessContext
public <R> R accessContext(ContextAccess<C,R> access) { contextLock.lock(); try { return access.access(context); } finally { contextLock.unlock(); } }
java
public <R> R accessContext(ContextAccess<C,R> access) { contextLock.lock(); try { return access.access(context); } finally { contextLock.unlock(); } }
[ "public", "<", "R", ">", "R", "accessContext", "(", "ContextAccess", "<", "C", ",", "R", ">", "access", ")", "{", "contextLock", ".", "lock", "(", ")", ";", "try", "{", "return", "access", ".", "access", "(", "context", ")", ";", "}", "finally", "{...
Provides thread save access to the context object. ContextAccess.access method is called inside a lock to prevent concurrent modification to the object. @param <R> Return type @param access @return
[ "Provides", "thread", "save", "access", "to", "the", "context", "object", ".", "ContextAccess", ".", "access", "method", "is", "called", "inside", "a", "lock", "to", "prevent", "concurrent", "modification", "to", "the", "object", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/SimpleWorkflow.java#L445-L456
152,750
marssa/footprint
src/main/java/org/marssa/footprint/datatypes/decimal/frequency/AFrequency.java
AFrequency.getHz
public MDecimal getHz() { MDecimal result = new MDecimal(currentUnit.getConverterTo(HERTZ) .convert(doubleValue())); logger.trace(MMarker.GETTER, "Converting from {} to Hertz : {}", currentUnit, result); return result; }
java
public MDecimal getHz() { MDecimal result = new MDecimal(currentUnit.getConverterTo(HERTZ) .convert(doubleValue())); logger.trace(MMarker.GETTER, "Converting from {} to Hertz : {}", currentUnit, result); return result; }
[ "public", "MDecimal", "getHz", "(", ")", "{", "MDecimal", "result", "=", "new", "MDecimal", "(", "currentUnit", ".", "getConverterTo", "(", "HERTZ", ")", ".", "convert", "(", "doubleValue", "(", ")", ")", ")", ";", "logger", ".", "trace", "(", "MMarker",...
Hz is the SI unit
[ "Hz", "is", "the", "SI", "unit" ]
2ca953c14f46adc320927c87c5ce1c36eb6c82de
https://github.com/marssa/footprint/blob/2ca953c14f46adc320927c87c5ce1c36eb6c82de/src/main/java/org/marssa/footprint/datatypes/decimal/frequency/AFrequency.java#L67-L73
152,751
jbundle/jbundle
thin/base/util/base64/src/main/java/org/jbundle/thin/base/util/base64/Base64.java
Base64.encodeSHA
public static byte[] encodeSHA(byte[] rgbValue) throws NoSuchAlgorithmException { MessageDigest md = MessageDigest.getInstance("SHA"); md.update(rgbValue); rgbValue = md.digest(); return rgbValue; }
java
public static byte[] encodeSHA(byte[] rgbValue) throws NoSuchAlgorithmException { MessageDigest md = MessageDigest.getInstance("SHA"); md.update(rgbValue); rgbValue = md.digest(); return rgbValue; }
[ "public", "static", "byte", "[", "]", "encodeSHA", "(", "byte", "[", "]", "rgbValue", ")", "throws", "NoSuchAlgorithmException", "{", "MessageDigest", "md", "=", "MessageDigest", ".", "getInstance", "(", "\"SHA\"", ")", ";", "md", ".", "update", "(", "rgbVal...
Returns the string run through the SHA hash. @param unencoded the string to encode @return the encoded form of the unencoded string
[ "Returns", "the", "string", "run", "through", "the", "SHA", "hash", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/util/base64/src/main/java/org/jbundle/thin/base/util/base64/Base64.java#L29-L37
152,752
jbundle/jbundle
thin/base/util/base64/src/main/java/org/jbundle/thin/base/util/base64/Base64.java
Base64.encodeToBytes
@Deprecated public static byte[] encodeToBytes(byte[] bytes) { try { char[] chars = Base64.encode(bytes); String string = new String(chars); return string.getBytes(DEFAULT_ENCODING); } catch (UnsupportedEncodingException e) { e.printStackTrace(); ...
java
@Deprecated public static byte[] encodeToBytes(byte[] bytes) { try { char[] chars = Base64.encode(bytes); String string = new String(chars); return string.getBytes(DEFAULT_ENCODING); } catch (UnsupportedEncodingException e) { e.printStackTrace(); ...
[ "@", "Deprecated", "public", "static", "byte", "[", "]", "encodeToBytes", "(", "byte", "[", "]", "bytes", ")", "{", "try", "{", "char", "[", "]", "chars", "=", "Base64", ".", "encode", "(", "bytes", ")", ";", "String", "string", "=", "new", "String",...
Encode this string as base64. @param string @return
[ "Encode", "this", "string", "as", "base64", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/util/base64/src/main/java/org/jbundle/thin/base/util/base64/Base64.java#L52-L63
152,753
jbundle/jbundle
thin/base/util/base64/src/main/java/org/jbundle/thin/base/util/base64/Base64.java
Base64.decode
@Deprecated public static String decode(String string) { try { byte[] bytes = Base64.decode(string.toCharArray()); return new String(bytes, DEFAULT_ENCODING); } catch (UnsupportedEncodingException e) { e.printStackTrace(); return null; } ...
java
@Deprecated public static String decode(String string) { try { byte[] bytes = Base64.decode(string.toCharArray()); return new String(bytes, DEFAULT_ENCODING); } catch (UnsupportedEncodingException e) { e.printStackTrace(); return null; } ...
[ "@", "Deprecated", "public", "static", "String", "decode", "(", "String", "string", ")", "{", "try", "{", "byte", "[", "]", "bytes", "=", "Base64", ".", "decode", "(", "string", ".", "toCharArray", "(", ")", ")", ";", "return", "new", "String", "(", ...
Decode this base64 string to a regular string. @param string @return
[ "Decode", "this", "base64", "string", "to", "a", "regular", "string", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/util/base64/src/main/java/org/jbundle/thin/base/util/base64/Base64.java#L95-L105
152,754
tvesalainen/util
util/src/main/java/org/vesalainen/math/matrix/Matrix.java
Matrix.set
public void set(int i, int j, T v) { consumer.set(i, j, v); }
java
public void set(int i, int j, T v) { consumer.set(i, j, v); }
[ "public", "void", "set", "(", "int", "i", ",", "int", "j", ",", "T", "v", ")", "{", "consumer", ".", "set", "(", "i", ",", "j", ",", "v", ")", ";", "}" ]
Sets item at i,j @param i @param j @param v
[ "Sets", "item", "at", "i", "j" ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/math/matrix/Matrix.java#L92-L95
152,755
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/thread/ProcessRunnerTask.java
ProcessRunnerTask.runTask
public void runTask() { String strProcess = this.getProperty(DBParams.PROCESS); BaseProcess job = (BaseProcess)ClassServiceUtility.getClassService().makeObjectFromClassName(strProcess); if (job != null) { this.runProcess(job, m_properties); } else ...
java
public void runTask() { String strProcess = this.getProperty(DBParams.PROCESS); BaseProcess job = (BaseProcess)ClassServiceUtility.getClassService().makeObjectFromClassName(strProcess); if (job != null) { this.runProcess(job, m_properties); } else ...
[ "public", "void", "runTask", "(", ")", "{", "String", "strProcess", "=", "this", ".", "getProperty", "(", "DBParams", ".", "PROCESS", ")", ";", "BaseProcess", "job", "=", "(", "BaseProcess", ")", "ClassServiceUtility", ".", "getClassService", "(", ")", ".", ...
Get the name of this process and run it.
[ "Get", "the", "name", "of", "this", "process", "and", "run", "it", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/thread/ProcessRunnerTask.java#L108-L143
152,756
jbundle/jbundle
app/program/db/src/main/java/org/jbundle/app/program/db/PropertiesStringField.java
PropertiesStringField.doGetData
public Object doGetData() { String data = (String)super.doGetData(); FileListener listener = this.getRecord().getListener(PropertiesStringFileListener.class); if (this.getComponent(0) == null) // Don't convert if this is linked to a screen if (enableConversion) ...
java
public Object doGetData() { String data = (String)super.doGetData(); FileListener listener = this.getRecord().getListener(PropertiesStringFileListener.class); if (this.getComponent(0) == null) // Don't convert if this is linked to a screen if (enableConversion) ...
[ "public", "Object", "doGetData", "(", ")", "{", "String", "data", "=", "(", "String", ")", "super", ".", "doGetData", "(", ")", ";", "FileListener", "listener", "=", "this", ".", "getRecord", "(", ")", ".", "getListener", "(", "PropertiesStringFileListener",...
DoGetData Method.
[ "DoGetData", "Method", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/app/program/db/src/main/java/org/jbundle/app/program/db/PropertiesStringField.java#L74-L84
152,757
jbundle/jbundle
app/program/screen/src/main/java/org/jbundle/app/program/screen/SwitchClassSub.java
SwitchClassSub.getSubScreen
public BasePanel getSubScreen(BasePanel parentScreen, ScreenLocation screenLocation, Map<String,Object> properties, int screenNo) { switch (screenNo) { case 0: return new LogicFileGridScreen(null, screenLocation, parentScreen, null, ScreenConstants.DONT_DISPLAY_FIELD_DESC, proper...
java
public BasePanel getSubScreen(BasePanel parentScreen, ScreenLocation screenLocation, Map<String,Object> properties, int screenNo) { switch (screenNo) { case 0: return new LogicFileGridScreen(null, screenLocation, parentScreen, null, ScreenConstants.DONT_DISPLAY_FIELD_DESC, proper...
[ "public", "BasePanel", "getSubScreen", "(", "BasePanel", "parentScreen", ",", "ScreenLocation", "screenLocation", ",", "Map", "<", "String", ",", "Object", ">", "properties", ",", "int", "screenNo", ")", "{", "switch", "(", "screenNo", ")", "{", "case", "0", ...
GetSubScreen Method.
[ "GetSubScreen", "Method", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/app/program/screen/src/main/java/org/jbundle/app/program/screen/SwitchClassSub.java#L56-L84
152,758
tvesalainen/util
util/src/main/java/org/vesalainen/nio/channels/vc/SelectableVirtualCircuit.java
SelectableVirtualCircuit.start
@Override public void start(Supplier<ExecutorService> executorFactory) throws IOException { future = executorFactory.get().submit(this); }
java
@Override public void start(Supplier<ExecutorService> executorFactory) throws IOException { future = executorFactory.get().submit(this); }
[ "@", "Override", "public", "void", "start", "(", "Supplier", "<", "ExecutorService", ">", "executorFactory", ")", "throws", "IOException", "{", "future", "=", "executorFactory", ".", "get", "(", ")", ".", "submit", "(", "this", ")", ";", "}" ]
Start virtual circuit @param executorFactory @throws IOException
[ "Start", "virtual", "circuit" ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/nio/channels/vc/SelectableVirtualCircuit.java#L91-L95
152,759
tvesalainen/util
util/src/main/java/org/vesalainen/nio/channels/vc/SelectableVirtualCircuit.java
SelectableVirtualCircuit.waitForFinish
@Override public void waitForFinish() throws IOException { if (future == null) { throw new IllegalStateException("not started"); } try { future.get(); } catch (InterruptedException | ExecutionException ex) { ...
java
@Override public void waitForFinish() throws IOException { if (future == null) { throw new IllegalStateException("not started"); } try { future.get(); } catch (InterruptedException | ExecutionException ex) { ...
[ "@", "Override", "public", "void", "waitForFinish", "(", ")", "throws", "IOException", "{", "if", "(", "future", "==", "null", ")", "{", "throw", "new", "IllegalStateException", "(", "\"not started\"", ")", ";", "}", "try", "{", "future", ".", "get", "(", ...
Wait until other peer has closed connection or virtual circuit is closed by interrupt. @throws IOException
[ "Wait", "until", "other", "peer", "has", "closed", "connection", "or", "virtual", "circuit", "is", "closed", "by", "interrupt", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/nio/channels/vc/SelectableVirtualCircuit.java#L101-L116
152,760
eostermueller/headlessInTraceClient
src/main/java/org/headlessintrace/client/request/RequestConnection.java
RequestConnection.setRequestCompletionFilter
public void setRequestCompletionFilter(ITraceFilterExt val) { RequestWriter requestWriter = (RequestWriter) m_connection.getTraceWriter(); requestWriter.getRequestSeparator().setRequestCompletionFilter(val); }
java
public void setRequestCompletionFilter(ITraceFilterExt val) { RequestWriter requestWriter = (RequestWriter) m_connection.getTraceWriter(); requestWriter.getRequestSeparator().setRequestCompletionFilter(val); }
[ "public", "void", "setRequestCompletionFilter", "(", "ITraceFilterExt", "val", ")", "{", "RequestWriter", "requestWriter", "=", "(", "RequestWriter", ")", "m_connection", ".", "getTraceWriter", "(", ")", ";", "requestWriter", ".", "getRequestSeparator", "(", ")", "....
The request api will consider a thread is completed processing when a particular method fires an exit event. Which method? The one indicated on the parameters of this method. As you'd expect, this needs to be called before events start firing. This the inTrace client will not be running in the same JVM as the system ...
[ "The", "request", "api", "will", "consider", "a", "thread", "is", "completed", "processing", "when", "a", "particular", "method", "fires", "an", "exit", "event", ".", "Which", "method?", "The", "one", "indicated", "on", "the", "parameters", "of", "this", "me...
50b1dccc5ff9e342c7c1d06b5a382e8c0afc7604
https://github.com/eostermueller/headlessInTraceClient/blob/50b1dccc5ff9e342c7c1d06b5a382e8c0afc7604/src/main/java/org/headlessintrace/client/request/RequestConnection.java#L106-L109
152,761
microfocus-idol/java-logging
src/main/java/com/hp/autonomy/frontend/logging/ApplicationStartLogger.java
ApplicationStartLogger.onApplicationEvent
@Override public void onApplicationEvent(final ContextRefreshedEvent event) { if (!hasStarted) { hasStarted = true; log.info(Markers.AUDIT, message); } }
java
@Override public void onApplicationEvent(final ContextRefreshedEvent event) { if (!hasStarted) { hasStarted = true; log.info(Markers.AUDIT, message); } }
[ "@", "Override", "public", "void", "onApplicationEvent", "(", "final", "ContextRefreshedEvent", "event", ")", "{", "if", "(", "!", "hasStarted", ")", "{", "hasStarted", "=", "true", ";", "log", ".", "info", "(", "Markers", ".", "AUDIT", ",", "message", ")"...
Logs the provided message at log level info when it first receives an event
[ "Logs", "the", "provided", "message", "at", "log", "level", "info", "when", "it", "first", "receives", "an", "event" ]
f06f8547928897d07d41e046f53abcbbc3725271
https://github.com/microfocus-idol/java-logging/blob/f06f8547928897d07d41e046f53abcbbc3725271/src/main/java/com/hp/autonomy/frontend/logging/ApplicationStartLogger.java#L40-L46
152,762
tvesalainen/util
util/src/main/java/org/vesalainen/math/BezierCurve.java
BezierCurve.operator
public ParameterizedOperator operator(Point2D.Double... controlPoints) { if (controlPoints.length != length) { throw new IllegalArgumentException("control-points length not "+length); } double[] cp = convert(controlPoints); return operator(cp); }
java
public ParameterizedOperator operator(Point2D.Double... controlPoints) { if (controlPoints.length != length) { throw new IllegalArgumentException("control-points length not "+length); } double[] cp = convert(controlPoints); return operator(cp); }
[ "public", "ParameterizedOperator", "operator", "(", "Point2D", ".", "Double", "...", "controlPoints", ")", "{", "if", "(", "controlPoints", ".", "length", "!=", "length", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"control-points length not \"", "+...
Creates Bezier function for fixed control points. @param controlPoints @return
[ "Creates", "Bezier", "function", "for", "fixed", "control", "points", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/math/BezierCurve.java#L71-L79
152,763
tvesalainen/util
util/src/main/java/org/vesalainen/math/BezierCurve.java
BezierCurve.operator
public ParameterizedOperator operator(double... controlPoints) { if (controlPoints.length != 2*length) { throw new IllegalArgumentException("control-points length not "+length); } return operator(controlPoints, 0); }
java
public ParameterizedOperator operator(double... controlPoints) { if (controlPoints.length != 2*length) { throw new IllegalArgumentException("control-points length not "+length); } return operator(controlPoints, 0); }
[ "public", "ParameterizedOperator", "operator", "(", "double", "...", "controlPoints", ")", "{", "if", "(", "controlPoints", ".", "length", "!=", "2", "*", "length", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"control-points length not \"", "+", "...
Creates Bezier function for fixed control points. Note that it is not same if you pass an array or separate parameters. Array is not copied, so if you modify it it will make change. If you want to have function with immutable control points, use separate parameters or copy the array. @param controlPoints @return
[ "Creates", "Bezier", "function", "for", "fixed", "control", "points", ".", "Note", "that", "it", "is", "not", "same", "if", "you", "pass", "an", "array", "or", "separate", "parameters", ".", "Array", "is", "not", "copied", "so", "if", "you", "modify", "i...
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/math/BezierCurve.java#L88-L95
152,764
tvesalainen/util
util/src/main/java/org/vesalainen/math/BezierCurve.java
BezierCurve.derivative
private ParameterizedOperator derivative(double... controlPoints) { if (controlPoints.length != 2*length) { throw new IllegalArgumentException("control-points length not "+length); } return derivative(controlPoints, 0); }
java
private ParameterizedOperator derivative(double... controlPoints) { if (controlPoints.length != 2*length) { throw new IllegalArgumentException("control-points length not "+length); } return derivative(controlPoints, 0); }
[ "private", "ParameterizedOperator", "derivative", "(", "double", "...", "controlPoints", ")", "{", "if", "(", "controlPoints", ".", "length", "!=", "2", "*", "length", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"control-points length not \"", "+", ...
Create first derivative function for fixed control points. @param controlPoints @return
[ "Create", "first", "derivative", "function", "for", "fixed", "control", "points", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/math/BezierCurve.java#L105-L112
152,765
tvesalainen/util
util/src/main/java/org/vesalainen/math/BezierCurve.java
BezierCurve.secondDerivative
private ParameterizedOperator secondDerivative(double... controlPoints) { if (controlPoints.length != 2*length) { throw new IllegalArgumentException("control-points length not "+length); } return secondDerivative(controlPoints, 0); }
java
private ParameterizedOperator secondDerivative(double... controlPoints) { if (controlPoints.length != 2*length) { throw new IllegalArgumentException("control-points length not "+length); } return secondDerivative(controlPoints, 0); }
[ "private", "ParameterizedOperator", "secondDerivative", "(", "double", "...", "controlPoints", ")", "{", "if", "(", "controlPoints", ".", "length", "!=", "2", "*", "length", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"control-points length not \"", ...
Create second derivative function for fixed control points. @param controlPoints @return
[ "Create", "second", "derivative", "function", "for", "fixed", "control", "points", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/math/BezierCurve.java#L143-L150
152,766
tvesalainen/util
util/src/main/java/org/vesalainen/math/BezierCurve.java
BezierCurve.getInstance
public static BezierCurve getInstance(int degree) { if (degree < 1) { throw new IllegalArgumentException("illegal degree"); } switch (degree) { case 1: return LINE; case 2: return QUAD; ...
java
public static BezierCurve getInstance(int degree) { if (degree < 1) { throw new IllegalArgumentException("illegal degree"); } switch (degree) { case 1: return LINE; case 2: return QUAD; ...
[ "public", "static", "BezierCurve", "getInstance", "(", "int", "degree", ")", "{", "if", "(", "degree", "<", "1", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"illegal degree\"", ")", ";", "}", "switch", "(", "degree", ")", "{", "case", "1",...
Creates or gets BezierCurve instance @param degree @return
[ "Creates", "or", "gets", "BezierCurve", "instance" ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/math/BezierCurve.java#L171-L188
152,767
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/transport/email/MessageReceivingPopClient.java
MessageReceivingPopClient.main
public static void main(String args[]) { Map<String,Object> properties = null; if (args != null) { properties = new Hashtable<String,Object>(); Util.parseArgs(properties, args); } BaseApplication app = new MainApplication(null, properties, null); ...
java
public static void main(String args[]) { Map<String,Object> properties = null; if (args != null) { properties = new Hashtable<String,Object>(); Util.parseArgs(properties, args); } BaseApplication app = new MainApplication(null, properties, null); ...
[ "public", "static", "void", "main", "(", "String", "args", "[", "]", ")", "{", "Map", "<", "String", ",", "Object", ">", "properties", "=", "null", ";", "if", "(", "args", "!=", "null", ")", "{", "properties", "=", "new", "Hashtable", "<", "String", ...
Run this stand-alone.
[ "Run", "this", "stand", "-", "alone", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/transport/email/MessageReceivingPopClient.java#L63-L73
152,768
jbundle/jbundle
thin/base/db/misc/src/main/java/org/jbundle/thin/base/db/client/memory/MemoryRemoteTable.java
MemoryRemoteTable.doRemoteAction
public Object doRemoteAction(String strCommand, Map<String, Object> properties) throws DBException, RemoteException { return null; // Not supported }
java
public Object doRemoteAction(String strCommand, Map<String, Object> properties) throws DBException, RemoteException { return null; // Not supported }
[ "public", "Object", "doRemoteAction", "(", "String", "strCommand", ",", "Map", "<", "String", ",", "Object", ">", "properties", ")", "throws", "DBException", ",", "RemoteException", "{", "return", "null", ";", "// Not supported", "}" ]
Do a remote action. Not implemented. @param strCommand Command to perform remotely. @param properties Properties for this command (optional). @return boolean success.
[ "Do", "a", "remote", "action", ".", "Not", "implemented", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/db/misc/src/main/java/org/jbundle/thin/base/db/client/memory/MemoryRemoteTable.java#L304-L307
152,769
carewebframework/carewebframework-vista
org.carewebframework.vista.api-parent/org.carewebframework.vista.api.notification/src/main/java/org/carewebframework/vista/api/notification/Notification.java
Notification.setDfn
@Override public void setDfn(String dfn) { this.dfn = VistAUtil.validateIEN(dfn) ? dfn : null; }
java
@Override public void setDfn(String dfn) { this.dfn = VistAUtil.validateIEN(dfn) ? dfn : null; }
[ "@", "Override", "public", "void", "setDfn", "(", "String", "dfn", ")", "{", "this", ".", "dfn", "=", "VistAUtil", ".", "validateIEN", "(", "dfn", ")", "?", "dfn", ":", "null", ";", "}" ]
Sets the DFN of the associated patient, if any.
[ "Sets", "the", "DFN", "of", "the", "associated", "patient", "if", "any", "." ]
883b2cbe395d9e8a21cd19db820f0876bda6b1c6
https://github.com/carewebframework/carewebframework-vista/blob/883b2cbe395d9e8a21cd19db820f0876bda6b1c6/org.carewebframework.vista.api-parent/org.carewebframework.vista.api.notification/src/main/java/org/carewebframework/vista/api/notification/Notification.java#L129-L132
152,770
huangp/entityunit
src/main/java/com/github/huangp/entityunit/maker/PreferredValueMakersRegistry.java
PreferredValueMakersRegistry.add
public PreferredValueMakersRegistry add(Matcher<?> settableMatcher, Maker<?> maker) { Preconditions.checkNotNull(settableMatcher); Preconditions.checkNotNull(maker); makers.put(settableMatcher, maker); return this; }
java
public PreferredValueMakersRegistry add(Matcher<?> settableMatcher, Maker<?> maker) { Preconditions.checkNotNull(settableMatcher); Preconditions.checkNotNull(maker); makers.put(settableMatcher, maker); return this; }
[ "public", "PreferredValueMakersRegistry", "add", "(", "Matcher", "<", "?", ">", "settableMatcher", ",", "Maker", "<", "?", ">", "maker", ")", "{", "Preconditions", ".", "checkNotNull", "(", "settableMatcher", ")", ";", "Preconditions", ".", "checkNotNull", "(", ...
Add a maker with custom matcher. @param settableMatcher a matcher to match on com.github.huangp.entityunit.util.Settable#fullyQualifiedName() @param maker custom maker @return this
[ "Add", "a", "maker", "with", "custom", "matcher", "." ]
1a09b530149d707dbff7ff46f5428d9db709a4b4
https://github.com/huangp/entityunit/blob/1a09b530149d707dbff7ff46f5428d9db709a4b4/src/main/java/com/github/huangp/entityunit/maker/PreferredValueMakersRegistry.java#L34-L39
152,771
jmeetsma/Iglu-Util
src/main/java/org/ijsberg/iglu/util/formatting/PatternMatchingSupport.java
PatternMatchingSupport.valueMatchesRegularExpression
public static boolean valueMatchesRegularExpression(String val, String regexp) { Pattern p = cache.get(regexp); if(p == null) { p = Pattern.compile(regexp); cache.put(regexp, p); } return valueMatchesRegularExpression(val, p); }
java
public static boolean valueMatchesRegularExpression(String val, String regexp) { Pattern p = cache.get(regexp); if(p == null) { p = Pattern.compile(regexp); cache.put(regexp, p); } return valueMatchesRegularExpression(val, p); }
[ "public", "static", "boolean", "valueMatchesRegularExpression", "(", "String", "val", ",", "String", "regexp", ")", "{", "Pattern", "p", "=", "cache", ".", "get", "(", "regexp", ")", ";", "if", "(", "p", "==", "null", ")", "{", "p", "=", "Pattern", "."...
Returns true only if the value matches the regular expression only once and exactly. @param val string value that may match the expression @param regexp regular expression @return true if val matches regular expression regexp
[ "Returns", "true", "only", "if", "the", "value", "matches", "the", "regular", "expression", "only", "once", "and", "exactly", "." ]
971eb022115247b1e34dc26dd02e7e621e29e910
https://github.com/jmeetsma/Iglu-Util/blob/971eb022115247b1e34dc26dd02e7e621e29e910/src/main/java/org/ijsberg/iglu/util/formatting/PatternMatchingSupport.java#L46-L53
152,772
jmeetsma/Iglu-Util
src/main/java/org/ijsberg/iglu/util/formatting/PatternMatchingSupport.java
PatternMatchingSupport.valueMatchesRegularExpression
public static boolean valueMatchesRegularExpression(String val, Pattern regexp) { Matcher m = regexp.matcher(val); try { return m.matches(); } catch (StackOverflowError e) { e.printStackTrace(); System.out.println("-> [" + val + "][" + regexp + "]"); System.out.println("-> " + val.length()); Syste...
java
public static boolean valueMatchesRegularExpression(String val, Pattern regexp) { Matcher m = regexp.matcher(val); try { return m.matches(); } catch (StackOverflowError e) { e.printStackTrace(); System.out.println("-> [" + val + "][" + regexp + "]"); System.out.println("-> " + val.length()); Syste...
[ "public", "static", "boolean", "valueMatchesRegularExpression", "(", "String", "val", ",", "Pattern", "regexp", ")", "{", "Matcher", "m", "=", "regexp", ".", "matcher", "(", "val", ")", ";", "try", "{", "return", "m", ".", "matches", "(", ")", ";", "}", ...
Returns true only if the value matches the regular expression at least once. @param val string value that may match the expression @param regexp regular expression @return true if val matches regular expression regexp
[ "Returns", "true", "only", "if", "the", "value", "matches", "the", "regular", "expression", "at", "least", "once", "." ]
971eb022115247b1e34dc26dd02e7e621e29e910
https://github.com/jmeetsma/Iglu-Util/blob/971eb022115247b1e34dc26dd02e7e621e29e910/src/main/java/org/ijsberg/iglu/util/formatting/PatternMatchingSupport.java#L63-L75
152,773
simter/simter-jwt
src/main/java/tech/simter/jwt/Payload.java
Payload.decode
public static Payload decode(String base64) { JsonObject json = decodeToJson(base64); Payload payload = new Payload(); json.keySet().forEach(key -> { switch (key) { case "iss": payload.issuer = json.getString(key); break; case "sub": payload.subject = json...
java
public static Payload decode(String base64) { JsonObject json = decodeToJson(base64); Payload payload = new Payload(); json.keySet().forEach(key -> { switch (key) { case "iss": payload.issuer = json.getString(key); break; case "sub": payload.subject = json...
[ "public", "static", "Payload", "decode", "(", "String", "base64", ")", "{", "JsonObject", "json", "=", "decodeToJson", "(", "base64", ")", ";", "Payload", "payload", "=", "new", "Payload", "(", ")", ";", "json", ".", "keySet", "(", ")", ".", "forEach", ...
Decode the base64-string to Payload. @param base64 the base64-string to be decoded @return the payload instance
[ "Decode", "the", "base64", "-", "string", "to", "Payload", "." ]
fea8d520e8eeb26c2ab9f5eeb2bd3f5a6c0e4433
https://github.com/simter/simter-jwt/blob/fea8d520e8eeb26c2ab9f5eeb2bd3f5a6c0e4433/src/main/java/tech/simter/jwt/Payload.java#L117-L148
152,774
mbenson/therian
core/src/main/java/therian/operator/convert/DefaultCopyingConverter.java
DefaultCopyingConverter.perform
@Override @SuppressWarnings({ "unchecked" }) public boolean perform(TherianContext context, final Convert<?, ?> convert) { return new Delegate(convert).perform(context, convert); }
java
@Override @SuppressWarnings({ "unchecked" }) public boolean perform(TherianContext context, final Convert<?, ?> convert) { return new Delegate(convert).perform(context, convert); }
[ "@", "Override", "@", "SuppressWarnings", "(", "{", "\"unchecked\"", "}", ")", "public", "boolean", "perform", "(", "TherianContext", "context", ",", "final", "Convert", "<", "?", ",", "?", ">", "convert", ")", "{", "return", "new", "Delegate", "(", "conve...
specifically avoid doing typed ops as we want to catch stuff that slips through the cracks
[ "specifically", "avoid", "doing", "typed", "ops", "as", "we", "want", "to", "catch", "stuff", "that", "slips", "through", "the", "cracks" ]
0653505f73e2a6f5b0abc394ea6d83af03408254
https://github.com/mbenson/therian/blob/0653505f73e2a6f5b0abc394ea6d83af03408254/core/src/main/java/therian/operator/convert/DefaultCopyingConverter.java#L95-L99
152,775
huangp/entityunit
src/main/java/com/github/huangp/entityunit/entity/EntityCleaner.java
EntityCleaner.getAssociationTables
private static Iterable<String> getAssociationTables(EntityClass entityClass) { Iterable<Settable> association = filter(entityClass.getElements(), and(or(has(ManyToMany.class), has(ElementCollection.class)), has(JoinTable.class))); return transform(association, new Function<Settable, Str...
java
private static Iterable<String> getAssociationTables(EntityClass entityClass) { Iterable<Settable> association = filter(entityClass.getElements(), and(or(has(ManyToMany.class), has(ElementCollection.class)), has(JoinTable.class))); return transform(association, new Function<Settable, Str...
[ "private", "static", "Iterable", "<", "String", ">", "getAssociationTables", "(", "EntityClass", "entityClass", ")", "{", "Iterable", "<", "Settable", ">", "association", "=", "filter", "(", "entityClass", ".", "getElements", "(", ")", ",", "and", "(", "or", ...
This will find all ManyToMany and ElementCollection annotated tables.
[ "This", "will", "find", "all", "ManyToMany", "and", "ElementCollection", "annotated", "tables", "." ]
1a09b530149d707dbff7ff46f5428d9db709a4b4
https://github.com/huangp/entityunit/blob/1a09b530149d707dbff7ff46f5428d9db709a4b4/src/main/java/com/github/huangp/entityunit/entity/EntityCleaner.java#L140-L150
152,776
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.createCatalog
@Override public final void createCatalog(ClusterName targetCluster, CatalogMetadata catalogMetadata) throws ExecutionException, UnsupportedException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug...
java
@Override public final void createCatalog(ClusterName targetCluster, CatalogMetadata catalogMetadata) throws ExecutionException, UnsupportedException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug...
[ "@", "Override", "public", "final", "void", "createCatalog", "(", "ClusterName", "targetCluster", ",", "CatalogMetadata", "catalogMetadata", ")", "throws", "ExecutionException", ",", "UnsupportedException", "{", "try", "{", "connectionHandler", ".", "startJob", "(", "...
This method creates a catalog. @param targetCluster the target cluster where the catalog will be created. @param catalogMetadata the catalog metadata info. @throws UnsupportedException if an operation is not supported. @throws ExecutionException if an error happens.
[ "This", "method", "creates", "a", "catalog", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L78-L99
152,777
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.createTable
@Override public final void createTable(ClusterName targetCluster, TableMetadata tableMetadata) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Cre...
java
@Override public final void createTable(ClusterName targetCluster, TableMetadata tableMetadata) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Cre...
[ "@", "Override", "public", "final", "void", "createTable", "(", "ClusterName", "targetCluster", ",", "TableMetadata", "tableMetadata", ")", "throws", "UnsupportedException", ",", "ExecutionException", "{", "try", "{", "connectionHandler", ".", "startJob", "(", "target...
This method creates a table. @param targetCluster the target cluster where the table will be created. @param tableMetadata the table metadata. @throws UnsupportedException if an operation is not supported. @throws ExecutionException if an error happens.
[ "This", "method", "creates", "a", "table", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L109-L132
152,778
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.dropCatalog
@Override public final void dropCatalog(ClusterName targetCluster, CatalogName name) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Dropping catal...
java
@Override public final void dropCatalog(ClusterName targetCluster, CatalogName name) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Dropping catal...
[ "@", "Override", "public", "final", "void", "dropCatalog", "(", "ClusterName", "targetCluster", ",", "CatalogName", "name", ")", "throws", "UnsupportedException", ",", "ExecutionException", "{", "try", "{", "connectionHandler", ".", "startJob", "(", "targetCluster", ...
This method drop a catalog. @param targetCluster the target cluster where the catalog will be dropped. @param name the catalog name. @throws UnsupportedException if an operation is not supported. @throws ExecutionException if an error happens.
[ "This", "method", "drop", "a", "catalog", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L142-L164
152,779
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.dropTable
@Override public final void dropTable(ClusterName targetCluster, TableName name) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Dropping table [" ...
java
@Override public final void dropTable(ClusterName targetCluster, TableName name) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Dropping table [" ...
[ "@", "Override", "public", "final", "void", "dropTable", "(", "ClusterName", "targetCluster", ",", "TableName", "name", ")", "throws", "UnsupportedException", ",", "ExecutionException", "{", "try", "{", "connectionHandler", ".", "startJob", "(", "targetCluster", "."...
This method drop a table. @param targetCluster the target cluster where the table will be dropped. @param name the table name. @throws UnsupportedException if an operation is not supported. @throws ExecutionException if an error happens.
[ "This", "method", "drop", "a", "table", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L174-L196
152,780
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.createIndex
@Override public final void createIndex(ClusterName targetCluster, IndexMetadata indexMetadata) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Cre...
java
@Override public final void createIndex(ClusterName targetCluster, IndexMetadata indexMetadata) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logger.debug("Cre...
[ "@", "Override", "public", "final", "void", "createIndex", "(", "ClusterName", "targetCluster", ",", "IndexMetadata", "indexMetadata", ")", "throws", "UnsupportedException", ",", "ExecutionException", "{", "try", "{", "connectionHandler", ".", "startJob", "(", "target...
This method creates an index. @param targetCluster the target cluster where the index will be created. @param indexMetadata the index metainformation. @throws UnsupportedException if an operation is not supported. @throws ExecutionException if an error happens.
[ "This", "method", "creates", "an", "index", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L206-L230
152,781
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.alterTable
@Override public final void alterTable(ClusterName targetCluster, TableName name, AlterOptions alterOptions) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logge...
java
@Override public final void alterTable(ClusterName targetCluster, TableName name, AlterOptions alterOptions) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { logge...
[ "@", "Override", "public", "final", "void", "alterTable", "(", "ClusterName", "targetCluster", ",", "TableName", "name", ",", "AlterOptions", "alterOptions", ")", "throws", "UnsupportedException", ",", "ExecutionException", "{", "try", "{", "connectionHandler", ".", ...
This method add, delete, or modify columns in an existing table. @param targetCluster the target cluster where the table will be altered. @param name the table name. @param alterOptions the alter options. @throws UnsupportedException the unsupported exception @throws ExecutionException the execution except...
[ "This", "method", "add", "delete", "or", "modify", "columns", "in", "an", "existing", "table", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L270-L290
152,782
Stratio/stratio-connector-commons
connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java
CommonsMetadataEngine.alterCatalog
@Override public final void alterCatalog(ClusterName targetCluster, CatalogName catalogName, Map<Selector, Selector> options) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { ...
java
@Override public final void alterCatalog(ClusterName targetCluster, CatalogName catalogName, Map<Selector, Selector> options) throws UnsupportedException, ExecutionException { try { connectionHandler.startJob(targetCluster.getName()); if (logger.isDebugEnabled()) { ...
[ "@", "Override", "public", "final", "void", "alterCatalog", "(", "ClusterName", "targetCluster", ",", "CatalogName", "catalogName", ",", "Map", "<", "Selector", ",", "Selector", ">", "options", ")", "throws", "UnsupportedException", ",", "ExecutionException", "{", ...
Alter options in an existing table. @param targetCluster the target cluster where the catalog will be altered. @param catalogName the catalog name @param options the options @throws UnsupportedException if the operation is not supported @throws ExecutionException if any error happen during the execution
[ "Alter", "options", "in", "an", "existing", "table", "." ]
d7cc66cb9591344a13055962e87a91f01c3707d1
https://github.com/Stratio/stratio-connector-commons/blob/d7cc66cb9591344a13055962e87a91f01c3707d1/connector-commons/src/main/java/com/stratio/connector/commons/engine/CommonsMetadataEngine.java#L301-L321
152,783
probedock/probedock-rt-java
src/main/java/io/probedock/rt/client/Connector.java
Connector.notifyStart
public void notifyStart(String projectApiId, String projectVersion, String category) { try { if (isStarted()) { JSONObject startNotification = new JSONObject(). put("project", new JSONObject(). put("apiId", projectApiId). put("version", projectVersion) ). put("category", category); ...
java
public void notifyStart(String projectApiId, String projectVersion, String category) { try { if (isStarted()) { JSONObject startNotification = new JSONObject(). put("project", new JSONObject(). put("apiId", projectApiId). put("version", projectVersion) ). put("category", category); ...
[ "public", "void", "notifyStart", "(", "String", "projectApiId", ",", "String", "projectVersion", ",", "String", "category", ")", "{", "try", "{", "if", "(", "isStarted", "(", ")", ")", "{", "JSONObject", "startNotification", "=", "new", "JSONObject", "(", ")...
Send a starting notification to the agent @param projectApiId The project API ID @param projectVersion The project version @param category The category
[ "Send", "a", "starting", "notification", "to", "the", "agent" ]
67b44b64303b15eb2d4808f9560a1c9554ccf3ba
https://github.com/probedock/probedock-rt-java/blob/67b44b64303b15eb2d4808f9560a1c9554ccf3ba/src/main/java/io/probedock/rt/client/Connector.java#L62-L85
152,784
probedock/probedock-rt-java
src/main/java/io/probedock/rt/client/Connector.java
Connector.notifyEnd
public void notifyEnd(String projectApiId, String projectVersion, String category, long duration) { try { if (isStarted()) { JSONObject endNotification = new JSONObject(). put("project", new JSONObject(). put("apiId", projectApiId). put("version", projectVersion) ). put("category", c...
java
public void notifyEnd(String projectApiId, String projectVersion, String category, long duration) { try { if (isStarted()) { JSONObject endNotification = new JSONObject(). put("project", new JSONObject(). put("apiId", projectApiId). put("version", projectVersion) ). put("category", c...
[ "public", "void", "notifyEnd", "(", "String", "projectApiId", ",", "String", "projectVersion", ",", "String", "category", ",", "long", "duration", ")", "{", "try", "{", "if", "(", "isStarted", "(", ")", ")", "{", "JSONObject", "endNotification", "=", "new", ...
Send a ending notification to the agent @param projectApiId The project API ID @param projectVersion The project version @param category The category @param duration The duration of the test run
[ "Send", "a", "ending", "notification", "to", "the", "agent" ]
67b44b64303b15eb2d4808f9560a1c9554ccf3ba
https://github.com/probedock/probedock-rt-java/blob/67b44b64303b15eb2d4808f9560a1c9554ccf3ba/src/main/java/io/probedock/rt/client/Connector.java#L132-L156
152,785
probedock/probedock-rt-java
src/main/java/io/probedock/rt/client/Connector.java
Connector.send
public void send(TestRun testRun) { try { if (isStarted()) { ByteArrayOutputStream baos = new ByteArrayOutputStream(); new JsonSerializer().serializePayload(new OutputStreamWriter(baos), testRun, false); socket.emit("payload", new String(baos.toByteArray())); } else { LOGGER.log(Level.WARNI...
java
public void send(TestRun testRun) { try { if (isStarted()) { ByteArrayOutputStream baos = new ByteArrayOutputStream(); new JsonSerializer().serializePayload(new OutputStreamWriter(baos), testRun, false); socket.emit("payload", new String(baos.toByteArray())); } else { LOGGER.log(Level.WARNI...
[ "public", "void", "send", "(", "TestRun", "testRun", ")", "{", "try", "{", "if", "(", "isStarted", "(", ")", ")", "{", "ByteArrayOutputStream", "baos", "=", "new", "ByteArrayOutputStream", "(", ")", ";", "new", "JsonSerializer", "(", ")", ".", "serializePa...
Send a test result to the agent. This is a best effort and when the request failed, there is no crash @param testRun The result to send
[ "Send", "a", "test", "result", "to", "the", "agent", ".", "This", "is", "a", "best", "effort", "and", "when", "the", "request", "failed", "there", "is", "no", "crash" ]
67b44b64303b15eb2d4808f9560a1c9554ccf3ba
https://github.com/probedock/probedock-rt-java/blob/67b44b64303b15eb2d4808f9560a1c9554ccf3ba/src/main/java/io/probedock/rt/client/Connector.java#L163-L183
152,786
probedock/probedock-rt-java
src/main/java/io/probedock/rt/client/Connector.java
Connector.getFilters
public List<FilterDefinition> getFilters() { try { if (isStarted()) { final FilterAcknowledger acknowledger = new FilterAcknowledger(); // Be sure that the emit/ack is synchronous to get the filters before the test are run new Thread(new Runnable() { @Override public void run() { t...
java
public List<FilterDefinition> getFilters() { try { if (isStarted()) { final FilterAcknowledger acknowledger = new FilterAcknowledger(); // Be sure that the emit/ack is synchronous to get the filters before the test are run new Thread(new Runnable() { @Override public void run() { t...
[ "public", "List", "<", "FilterDefinition", ">", "getFilters", "(", ")", "{", "try", "{", "if", "(", "isStarted", "(", ")", ")", "{", "final", "FilterAcknowledger", "acknowledger", "=", "new", "FilterAcknowledger", "(", ")", ";", "// Be sure that the emit/ack is ...
Try to get a filter list from the agent @return The list of filters or null if there is none or the agent is not accessible
[ "Try", "to", "get", "a", "filter", "list", "from", "the", "agent" ]
67b44b64303b15eb2d4808f9560a1c9554ccf3ba
https://github.com/probedock/probedock-rt-java/blob/67b44b64303b15eb2d4808f9560a1c9554ccf3ba/src/main/java/io/probedock/rt/client/Connector.java#L190-L234
152,787
probedock/probedock-rt-java
src/main/java/io/probedock/rt/client/Connector.java
Connector.createConnectedSocket
private Socket createConnectedSocket(final String url) { try { final Socket initSocket = IO.socket(url); final Callback callback = new Callback(); initSocket.on(Socket.EVENT_CONNECT, callback); initSocket.on(Socket.EVENT_CONNECT_ERROR, callback); initSocket.on(Socket.EVENT_CONNECT_TIMEOUT, callbac...
java
private Socket createConnectedSocket(final String url) { try { final Socket initSocket = IO.socket(url); final Callback callback = new Callback(); initSocket.on(Socket.EVENT_CONNECT, callback); initSocket.on(Socket.EVENT_CONNECT_ERROR, callback); initSocket.on(Socket.EVENT_CONNECT_TIMEOUT, callbac...
[ "private", "Socket", "createConnectedSocket", "(", "final", "String", "url", ")", "{", "try", "{", "final", "Socket", "initSocket", "=", "IO", ".", "socket", "(", "url", ")", ";", "final", "Callback", "callback", "=", "new", "Callback", "(", ")", ";", "i...
Create a new connection to the agent @param url The URL @return The socket connected to the agent or null if the connection is not possible
[ "Create", "a", "new", "connection", "to", "the", "agent" ]
67b44b64303b15eb2d4808f9560a1c9554ccf3ba
https://github.com/probedock/probedock-rt-java/blob/67b44b64303b15eb2d4808f9560a1c9554ccf3ba/src/main/java/io/probedock/rt/client/Connector.java#L242-L280
152,788
tvesalainen/util
util/src/main/java/org/vesalainen/util/DoubleStack.java
DoubleStack.push
public void push(double value) { if (top >= stack.length) { stack = Arrays.copyOf(stack, (int) (stack.length*growFactor)); } stack[top++] = value; }
java
public void push(double value) { if (top >= stack.length) { stack = Arrays.copyOf(stack, (int) (stack.length*growFactor)); } stack[top++] = value; }
[ "public", "void", "push", "(", "double", "value", ")", "{", "if", "(", "top", ">=", "stack", ".", "length", ")", "{", "stack", "=", "Arrays", ".", "copyOf", "(", "stack", ",", "(", "int", ")", "(", "stack", ".", "length", "*", "growFactor", ")", ...
Adds value to the top. @param value
[ "Adds", "value", "to", "the", "top", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/DoubleStack.java#L63-L70
152,789
tvesalainen/util
util/src/main/java/org/vesalainen/util/DoubleStack.java
DoubleStack.dup
@Override public void dup() { if (top < 1) { throw new EmptyStackException(); } if (top >= stack.length) { stack = Arrays.copyOf(stack, (int) (stack.length*growFactor)); } top++; stack[top-1] = stack[top-2]; ...
java
@Override public void dup() { if (top < 1) { throw new EmptyStackException(); } if (top >= stack.length) { stack = Arrays.copyOf(stack, (int) (stack.length*growFactor)); } top++; stack[top-1] = stack[top-2]; ...
[ "@", "Override", "public", "void", "dup", "(", ")", "{", "if", "(", "top", "<", "1", ")", "{", "throw", "new", "EmptyStackException", "(", ")", ";", "}", "if", "(", "top", ">=", "stack", ".", "length", ")", "{", "stack", "=", "Arrays", ".", "copy...
Top element is pushed.
[ "Top", "element", "is", "pushed", "." ]
bba7a44689f638ffabc8be40a75bdc9a33676433
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/DoubleStack.java#L131-L144
152,790
jbundle/jbundle
app/program/script/src/main/java/org/jbundle/app/program/script/data/importfix/base/FixCapitalization.java
FixCapitalization.fixRecord
public void fixRecord(Record record) { super.fixRecord(record); if (this.getProperty("field") != null) { BaseField field = this.getMainRecord().getField(this.getProperty("field").toString()); if (field != null) this.fixCapitalization(field); } ...
java
public void fixRecord(Record record) { super.fixRecord(record); if (this.getProperty("field") != null) { BaseField field = this.getMainRecord().getField(this.getProperty("field").toString()); if (field != null) this.fixCapitalization(field); } ...
[ "public", "void", "fixRecord", "(", "Record", "record", ")", "{", "super", ".", "fixRecord", "(", "record", ")", ";", "if", "(", "this", ".", "getProperty", "(", "\"field\"", ")", "!=", "null", ")", "{", "BaseField", "field", "=", "this", ".", "getMain...
FixRecord Method.
[ "FixRecord", "Method", "." ]
4037fcfa85f60c7d0096c453c1a3cd573c2b0abc
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/app/program/script/src/main/java/org/jbundle/app/program/script/data/importfix/base/FixCapitalization.java#L54-L63
152,791
krotscheck/jersey2-toolkit
jersey2-hibernate/src/main/java/net/krotscheck/jersey2/hibernate/factory/FulltextSessionFactory.java
FulltextSessionFactory.dispose
@Override public void dispose(final FullTextSession session) { if (session != null && session.isOpen()) { logger.trace("Disposing of hibernate fulltext session."); session.close(); } }
java
@Override public void dispose(final FullTextSession session) { if (session != null && session.isOpen()) { logger.trace("Disposing of hibernate fulltext session."); session.close(); } }
[ "@", "Override", "public", "void", "dispose", "(", "final", "FullTextSession", "session", ")", "{", "if", "(", "session", "!=", "null", "&&", "session", ".", "isOpen", "(", ")", ")", "{", "logger", ".", "trace", "(", "\"Disposing of hibernate fulltext session....
Dispose of the fulltext session if it hasn't already been closed. @param session The fulltext session to dispose of.
[ "Dispose", "of", "the", "fulltext", "session", "if", "it", "hasn", "t", "already", "been", "closed", "." ]
11d757bd222dc82ada462caf6730ba4ff85dae04
https://github.com/krotscheck/jersey2-toolkit/blob/11d757bd222dc82ada462caf6730ba4ff85dae04/jersey2-hibernate/src/main/java/net/krotscheck/jersey2/hibernate/factory/FulltextSessionFactory.java#L76-L82
152,792
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.getTranslatedContentSpecById
public static TranslatedContentSpecWrapper getTranslatedContentSpecById(final DataProviderFactory providerFactory, final Integer id, final Integer rev) { final CollectionWrapper<TranslatedContentSpecWrapper> translatedContentSpecs = providerFactory.getProvider( ContentSpecProvider.cl...
java
public static TranslatedContentSpecWrapper getTranslatedContentSpecById(final DataProviderFactory providerFactory, final Integer id, final Integer rev) { final CollectionWrapper<TranslatedContentSpecWrapper> translatedContentSpecs = providerFactory.getProvider( ContentSpecProvider.cl...
[ "public", "static", "TranslatedContentSpecWrapper", "getTranslatedContentSpecById", "(", "final", "DataProviderFactory", "providerFactory", ",", "final", "Integer", "id", ",", "final", "Integer", "rev", ")", "{", "final", "CollectionWrapper", "<", "TranslatedContentSpecWrap...
Gets a translated content spec based on a content spec id and revision
[ "Gets", "a", "translated", "content", "spec", "based", "on", "a", "content", "spec", "id", "and", "revision" ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L97-L114
152,793
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.getClosestTranslatedContentSpecById
public static TranslatedContentSpecWrapper getClosestTranslatedContentSpecById(final DataProviderFactory providerFactory, final Integer id, final Integer rev) { final CollectionWrapper<TranslatedContentSpecWrapper> translatedContentSpecs = providerFactory.getProvider(ContentSpecProvider ...
java
public static TranslatedContentSpecWrapper getClosestTranslatedContentSpecById(final DataProviderFactory providerFactory, final Integer id, final Integer rev) { final CollectionWrapper<TranslatedContentSpecWrapper> translatedContentSpecs = providerFactory.getProvider(ContentSpecProvider ...
[ "public", "static", "TranslatedContentSpecWrapper", "getClosestTranslatedContentSpecById", "(", "final", "DataProviderFactory", "providerFactory", ",", "final", "Integer", "id", ",", "final", "Integer", "rev", ")", "{", "final", "CollectionWrapper", "<", "TranslatedContentS...
Gets a translated content spec based on a id and revision. The translated content spec that is returned will be less then or equal to the revision that is passed. If the revision is null then the latest translated content spec will be returned. @param providerFactory @param id The Content Spec ID to find ...
[ "Gets", "a", "translated", "content", "spec", "based", "on", "a", "id", "and", "revision", ".", "The", "translated", "content", "spec", "that", "is", "returned", "will", "be", "less", "then", "or", "equal", "to", "the", "revision", "that", "is", "passed", ...
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L125-L147
152,794
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.getCategoryMappingFromTagList
public static Map<Integer, List<TagWrapper>> getCategoryMappingFromTagList(final Collection<TagWrapper> tags) { final HashMap<Integer, List<TagWrapper>> mapping = new HashMap<Integer, List<TagWrapper>>(); for (final TagWrapper tag : tags) { final List<CategoryInTagWrapper> catList = tag.getC...
java
public static Map<Integer, List<TagWrapper>> getCategoryMappingFromTagList(final Collection<TagWrapper> tags) { final HashMap<Integer, List<TagWrapper>> mapping = new HashMap<Integer, List<TagWrapper>>(); for (final TagWrapper tag : tags) { final List<CategoryInTagWrapper> catList = tag.getC...
[ "public", "static", "Map", "<", "Integer", ",", "List", "<", "TagWrapper", ">", ">", "getCategoryMappingFromTagList", "(", "final", "Collection", "<", "TagWrapper", ">", "tags", ")", "{", "final", "HashMap", "<", "Integer", ",", "List", "<", "TagWrapper", ">...
Converts a list of tags into a mapping of categories to tags. The key is the Category and the value is a List of Tags for that category. @param tags The List of tags to be converted. @return The mapping of Categories to Tags.
[ "Converts", "a", "list", "of", "tags", "into", "a", "mapping", "of", "categories", "to", "tags", ".", "The", "key", "is", "the", "Category", "and", "the", "value", "is", "a", "List", "of", "Tags", "for", "that", "category", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L348-L362
152,795
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.getCSNodeTopicEntity
public static TopicWrapper getCSNodeTopicEntity(final CSNodeWrapper node, final TopicProvider topicProvider) { if (!isNodeATopic(node)) return null; return topicProvider.getTopic(node.getEntityId(), node.getEntityRevision()); }
java
public static TopicWrapper getCSNodeTopicEntity(final CSNodeWrapper node, final TopicProvider topicProvider) { if (!isNodeATopic(node)) return null; return topicProvider.getTopic(node.getEntityId(), node.getEntityRevision()); }
[ "public", "static", "TopicWrapper", "getCSNodeTopicEntity", "(", "final", "CSNodeWrapper", "node", ",", "final", "TopicProvider", "topicProvider", ")", "{", "if", "(", "!", "isNodeATopic", "(", "node", ")", ")", "return", "null", ";", "return", "topicProvider", ...
Gets the CSNode Topic entity that is represented by the node. @param node The node that represents a topic entry. @param topicProvider The topic provider to lookup the topic entity from. @return The topic entity represented by the node, or null if there isn't one that matches.
[ "Gets", "the", "CSNode", "Topic", "entity", "that", "is", "represented", "by", "the", "node", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L371-L375
152,796
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.isNodeATopic
public static boolean isNodeATopic(final BaseCSNodeWrapper<?> node) { switch (node.getNodeType()) { case CommonConstants.CS_NODE_TOPIC: case CommonConstants.CS_NODE_INITIAL_CONTENT_TOPIC: case CommonConstants.CS_NODE_META_DATA_TOPIC: return true; d...
java
public static boolean isNodeATopic(final BaseCSNodeWrapper<?> node) { switch (node.getNodeType()) { case CommonConstants.CS_NODE_TOPIC: case CommonConstants.CS_NODE_INITIAL_CONTENT_TOPIC: case CommonConstants.CS_NODE_META_DATA_TOPIC: return true; d...
[ "public", "static", "boolean", "isNodeATopic", "(", "final", "BaseCSNodeWrapper", "<", "?", ">", "node", ")", "{", "switch", "(", "node", ".", "getNodeType", "(", ")", ")", "{", "case", "CommonConstants", ".", "CS_NODE_TOPIC", ":", "case", "CommonConstants", ...
Checks to see if the node is some representation of a Topic entity. @param node The node to be checked. @return
[ "Checks", "to", "see", "if", "the", "node", "is", "some", "representation", "of", "a", "Topic", "entity", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L383-L392
152,797
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.isNodeALevel
public static boolean isNodeALevel(final BaseCSNodeWrapper<?> node) { switch (node.getNodeType()) { case CommonConstants.CS_NODE_APPENDIX: case CommonConstants.CS_NODE_CHAPTER: case CommonConstants.CS_NODE_PART: case CommonConstants.CS_NODE_PREFACE: ca...
java
public static boolean isNodeALevel(final BaseCSNodeWrapper<?> node) { switch (node.getNodeType()) { case CommonConstants.CS_NODE_APPENDIX: case CommonConstants.CS_NODE_CHAPTER: case CommonConstants.CS_NODE_PART: case CommonConstants.CS_NODE_PREFACE: ca...
[ "public", "static", "boolean", "isNodeALevel", "(", "final", "BaseCSNodeWrapper", "<", "?", ">", "node", ")", "{", "switch", "(", "node", ".", "getNodeType", "(", ")", ")", "{", "case", "CommonConstants", ".", "CS_NODE_APPENDIX", ":", "case", "CommonConstants"...
Checks to see if an entity node is a level representation. @param node @return
[ "Checks", "to", "see", "if", "an", "entity", "node", "is", "a", "level", "representation", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L400-L413
152,798
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.hasContentSpecMetaDataChanged
public static boolean hasContentSpecMetaDataChanged(final String metaDataName, final String currentValue, final ContentSpecWrapper contentSpecEntity) { final CSNodeWrapper metaData = contentSpecEntity.getMetaData(metaDataName); if (metaData != null && metaData.getAdditionalText() != null && ...
java
public static boolean hasContentSpecMetaDataChanged(final String metaDataName, final String currentValue, final ContentSpecWrapper contentSpecEntity) { final CSNodeWrapper metaData = contentSpecEntity.getMetaData(metaDataName); if (metaData != null && metaData.getAdditionalText() != null && ...
[ "public", "static", "boolean", "hasContentSpecMetaDataChanged", "(", "final", "String", "metaDataName", ",", "final", "String", "currentValue", ",", "final", "ContentSpecWrapper", "contentSpecEntity", ")", "{", "final", "CSNodeWrapper", "metaData", "=", "contentSpecEntity...
Checks to see if a Content Spec Meta Data element has changed. @param metaDataName The Content Spec Meta Data name. @param currentValue The expected current value of the Meta Data node. @param contentSpecEntity The Content Spec Entity to check against. @return True if the meta data node has changed, otherwis...
[ "Checks", "to", "see", "if", "a", "Content", "Spec", "Meta", "Data", "element", "has", "changed", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L423-L435
152,799
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java
EntityUtilities.findLocaleFromString
public static LocaleWrapper findLocaleFromString(final CollectionWrapper<LocaleWrapper> locales, final String localeString) { if (localeString == null) return null; for (final LocaleWrapper locale : locales.getItems()) { if (localeString.equals(locale.getValue())) { return l...
java
public static LocaleWrapper findLocaleFromString(final CollectionWrapper<LocaleWrapper> locales, final String localeString) { if (localeString == null) return null; for (final LocaleWrapper locale : locales.getItems()) { if (localeString.equals(locale.getValue())) { return l...
[ "public", "static", "LocaleWrapper", "findLocaleFromString", "(", "final", "CollectionWrapper", "<", "LocaleWrapper", ">", "locales", ",", "final", "String", "localeString", ")", "{", "if", "(", "localeString", "==", "null", ")", "return", "null", ";", "for", "(...
Finds the matching locale entity from a locale string. @param localeProvider @param localeString @return
[ "Finds", "the", "matching", "locale", "entity", "from", "a", "locale", "string", "." ]
2bc02e2971e4522b47a130fb7ae5a0f5ad377df1
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/EntityUtilities.java#L452-L462