signature
stringlengths
43
39.1k
implementation
stringlengths
0
450k
public class CmsSearchIndexSource { /** * Returns < code > true < / code > in case the given resource root path is contained in the list of * configured resource names of this index source . < p > * @ param rootPath the resource root path to check * @ return < code > true < / code > in case the given resource roo...
if ( ( rootPath != null ) && ( m_resourcesNames != null ) ) { Iterator < String > i = m_resourcesNames . iterator ( ) ; while ( i . hasNext ( ) ) { String path = i . next ( ) ; if ( rootPath . startsWith ( path ) ) { return true ; } } } return false ;
public class DefaultBeanManager { /** * The direct , but no further , successors that references this bean will also be * fetched and initialized with their direct , but no further , predecessors . */ @ Override public Map < BeanId , Bean > getBeanToValidate ( Collection < Bean > beans ) throws AbortRuntimeException ...
Map < BeanId , Bean > beansToValidate = new HashMap < > ( ) ; for ( Bean bean : beans ) { Map < BeanId , Bean > predecessors = new HashMap < > ( ) ; // beans read from xml storage will only have their basic properties initialized . . . // . . . but we also need set the direct references / predecessors for beans to vali...
public class LocalScheduler { /** * Start the monitor of a given executor */ @ VisibleForTesting protected void startExecutorMonitor ( final int container , final Process containerExecutor , Set < PackingPlan . InstancePlan > instances ) { } }
// add the container for monitoring Runnable r = new Runnable ( ) { @ Override public void run ( ) { try { LOG . info ( "Waiting for container " + container + " to finish." ) ; containerExecutor . waitFor ( ) ; LOG . log ( Level . INFO , "Container {0} is completed. Exit status: {1}" , new Object [ ] { container , cont...
public class SearchPortletController { /** * Display a search form */ @ RequestMapping public ModelAndView showSearchForm ( RenderRequest request , RenderResponse response ) { } }
final Map < String , Object > model = new HashMap < > ( ) ; String viewName ; // Determine if the new REST search should be used if ( isRestSearch ( request ) ) { viewName = "/jsp/Search/searchRest" ; } else { // Determine if this portlet displays the search launch view or regular search view . final boolean isMobile =...
public class ResultUtil { /** * 处理es特殊字符 * @ param condition * @ return */ public static String handleElasticSearchSpecialChars ( String condition ) { } }
if ( condition == null || condition . equals ( "" ) ) { return condition ; } condition = condition . replace ( ":" , "\\:" ) ; condition = condition . replace ( "-" , "\\-" ) ; condition = condition . replace ( "+" , "\\+" ) ; condition = condition . replace ( "&" , "\\&" ) ; condition = condition . replace ( "!" , "\\...
public class CommerceSubscriptionEntryPersistenceImpl { /** * Returns the last commerce subscription entry in the ordered set where uuid = & # 63 ; . * @ param uuid the uuid * @ param orderByComparator the comparator to order the set by ( optionally < code > null < / code > ) * @ return the last matching commerce...
CommerceSubscriptionEntry commerceSubscriptionEntry = fetchByUuid_Last ( uuid , orderByComparator ) ; if ( commerceSubscriptionEntry != null ) { return commerceSubscriptionEntry ; } StringBundler msg = new StringBundler ( 4 ) ; msg . append ( _NO_SUCH_ENTITY_WITH_KEY ) ; msg . append ( "uuid=" ) ; msg . append ( uuid )...
public class CommerceAccountUserRelUtil { /** * Returns a range of all the commerce account user rels where commerceAccountUserId = & # 63 ; . * Useful when paginating results . Returns a maximum of < code > end - start < / code > instances . < code > start < / code > and < code > end < / code > are not primary keys ...
return getPersistence ( ) . findByCommerceAccountUserId ( commerceAccountUserId , start , end ) ;
public class HtmlTableRendererBase { /** * Perform any operations necessary after TABLE start tag is output * but before the TBODY start tag . * This method generates the THEAD / TFOOT sections of a table if there * are any header or footer facets defined on the table or on any child * UIColumn component . * ...
ResponseWriter writer = facesContext . getResponseWriter ( ) ; renderCaptionFacet ( facesContext , writer , uiData ) ; renderColgroupsFacet ( facesContext , writer , uiData ) ; renderFacet ( facesContext , writer , uiData , true ) ; renderFacet ( facesContext , writer , uiData , false ) ;
public class TableSession { /** * Process the command . * Step 1 - Process the command if possible and return true if processed . * Step 2 - If I can ' t process , pass to all children ( with me as the source ) . * Step 3 - If children didn ' t process , pass to parent ( with me as the source ) . * Note : Never...
int iRecordCount = m_vRecordList . getRecordCount ( ) ; int iOldMasterSlave = this . setMasterSlave ( RecordOwner . SLAVE | RecordOwner . MASTER ) ; Record record = this . getMainRecord ( ) ; if ( properties != null ) if ( Boolean . TRUE . equals ( properties . get ( MenuConstants . CLONE ) ) ) if ( record . getClass (...
public class ProcessTree { /** * Destroy the process group . * @ param pgrpId Process group id of to - be - killed - processes * @ param sleeptimeBeforeSigkill The time to wait before sending SIGKILL * after sending SIGTERM * @ param inBackground Process group is to be killed in the back ground with * a separ...
terminateProcessGroup ( pgrpId ) ; sigKill ( pgrpId , true , sleeptimeBeforeSigkill , inBackground ) ;
public class BitMap { /** * copy the byte value into the map at given position ( 0 , 24) */ public static int setByte ( int map , byte value , int pos ) { } }
int intValue = ( value & 0xff ) << ( 24 - pos ) ; int mask = 0xff000000 >>> pos ; mask = ~ mask ; map &= mask ; return ( map | intValue ) ;
public class PebbleDictionary { /** * Associate the specified unsigned int with the provided key in the dictionary . If another key - value pair with the * same key is already present in the dictionary , it will be replaced . * @ param key * key with which the specified value is associated * @ param i * value...
PebbleTuple t = PebbleTuple . create ( key , PebbleTuple . TupleType . UINT , PebbleTuple . Width . WORD , i ) ; addTuple ( t ) ;
public class HorizontalExpandableAdapter { /** * OnCreateViewHolder implementation for parent items . The desired ParentViewHolder should * be inflated here * @ param parent for inflating the View * @ return the user ' s custom parent ViewHolder that must extend ParentViewHolder */ @ UiThread @ NonNull @ Override...
View view = mInflater . inflate ( R . layout . list_item_parent_horizontal , parent , false ) ; return new HorizontalParentViewHolder ( view ) ;
public class BatchCheckLayerAvailabilityResult { /** * Any failures associated with the call . * < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use * { @ link # setFailures ( java . util . Collection ) } or { @ link # withFailures ( java . util . Collection ) } if you want to ...
if ( this . failures == null ) { setFailures ( new java . util . ArrayList < LayerFailure > ( failures . length ) ) ; } for ( LayerFailure ele : failures ) { this . failures . add ( ele ) ; } return this ;
public class HashIntSet { /** * Computes the number of buckets needed to provide the given capacity with the specified load * factor . */ protected static int getBucketCount ( int capacity , float loadFactor ) { } }
int size = ( int ) ( capacity / loadFactor ) ; int highest = Integer . highestOneBit ( size ) ; return Math . max ( ( size == highest ) ? highest : ( highest << 1 ) , MIN_BUCKET_COUNT ) ;
public class ElementList { /** * adds contents */ protected void build ( List xmlElements , boolean interpreteAsXHTML ) throws ParseException { } }
this . interpreteAsXHTML = interpreteAsXHTML ; int nrofElements = xmlElements . size ( ) ; for ( int i = 0 ; i < nrofElements ; i ++ ) { Object element = xmlElements . get ( i ) ; if ( element instanceof Node ) { this . addNode ( ( Node ) element ) ; } else if ( element instanceof Tag ) { Tag subtag = ( Tag ) element ;...
public class LifecycleHooks { /** * Get reference to an instance of the specified listener type . * @ param < T > listener type * @ param listenerType listener type * @ return optional listener instance */ public static < T extends RunListener > Optional < T > getAttachedListener ( Class < T > listenerType ) { } ...
return Run . getAttachedListener ( listenerType ) ;
public class StringValue { /** * Sets the value of the StringValue to a substring of the given string . * @ param value The new string value . * @ param offset The position to start the substring . * @ param len The length of the substring . */ public void setValue ( CharSequence value , int offset , int len ) { ...
checkNotNull ( value ) ; if ( offset < 0 || len < 0 || offset > value . length ( ) - len ) { throw new IndexOutOfBoundsException ( "offset: " + offset + " len: " + len + " value.len: " + len ) ; } ensureSize ( len ) ; this . len = len ; for ( int i = 0 ; i < len ; i ++ ) { this . value [ i ] = value . charAt ( offset +...
public class TimeUnit { /** * 时 - 规范化方法 * 该方法识别时间表达式单元的时字段 */ public void norm_sethour ( ) { } }
/* * 清除只能识别11-99时的bug * modified by 曹零 */ String rule = "(?<!(周|星期))([0-2]?[0-9])(?=(点|时))" ; Pattern pattern = Pattern . compile ( rule ) ; Matcher match = pattern . matcher ( Time_Expression ) ; if ( match . find ( ) ) { _tp . tunit [ 3 ] = Integer . parseInt ( match . group ( ) ) ; } /* * 对关键字 : 中午 , 午间 , 下午 , 午后 ...
public class Solo { /** * Clicks the specified WebElement . * @ param webElement the WebElement to click */ public void clickOnWebElement ( WebElement webElement ) { } }
if ( config . commandLogging ) { Log . d ( config . commandLoggingTag , "clickOnWebElement(" + webElement + ")" ) ; } if ( webElement == null ) Assert . fail ( "WebElement is null and can therefore not be clicked!" ) ; clicker . clickOnScreen ( webElement . getLocationX ( ) , webElement . getLocationY ( ) , null ) ;
public class Graphics { /** * Draw the the given shape filled in with a texture * @ param shape * The shape to texture . * @ param image * The image to tile across the shape * @ param fit * True if we want to fit the image on to the shape */ public void texture ( Shape shape , Image image , boolean fit ) { ...
if ( fit ) { texture ( shape , image , 1 , 1 , true ) ; } else { texture ( shape , image , 0.01f , 0.01f , false ) ; }
public class MemoryInfo { /** * Get information about the current memory status of the JVM . * @ param unit * used for formatting . Valid values are : * < ul > * < li > { @ link Unit # BYTES } < / li > * < li > { @ link Unit # KILOBYTES } < / li > * < li > { @ link Unit # KIBIBYTES } < / li > * < li > { @...
final long [ ] memory = getMemoryInfo ( ) ; for ( final Type type : Type . values ( ) ) { memory [ type . ordinal ( ) ] /= unit . getDenominator ( ) ; } final StringBuilder sb = new StringBuilder ( 100 ) ; sb . append ( "Memory (free/total/max): " ) ; sb . append ( memory [ Type . FREE . ordinal ( ) ] ) ; sb . append (...
public class FeedbackDemo { /** * Initializes the frame by creating its contents . */ private void initComponents ( ) { } }
setTitle ( "Validation Framework Test" ) ; setDefaultCloseOperation ( WindowConstants . EXIT_ON_CLOSE ) ; // Create content pane String notForNimbus ; if ( "Nimbus" . equals ( UIManager . getLookAndFeel ( ) . getName ( ) ) ) { notForNimbus = "" ; } else { notForNimbus = "related[]" ; } JPanel contentPane = new JPanel (...
public class AbstractLayout3DPC { /** * Find the " optimal " root of a spanning tree . Optimal in the sense of : one of * the most central nodes . * This uses a simple message passing approach . Every node that has only one * unset neighbor will emit a message to this neighbor . The node last to emit * wins . ...
final int size = ( msg . length >> 1 ) + 1 ; int [ ] depth = new int [ size ] , missing = new int [ size ] ; // We shouldn ' t need more iterations in any case ever . int root = - 1 ; for ( int i = 1 ; i < size ; i ++ ) { boolean active = false ; for ( int e = 1 ; e < msg . length ; e += 2 ) { if ( depth [ msg [ e - 1 ...
public class AttachPolicyRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( AttachPolicyRequest attachPolicyRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( attachPolicyRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( attachPolicyRequest . getDirectoryArn ( ) , DIRECTORYARN_BINDING ) ; protocolMarshaller . marshall ( attachPolicyRequest . getPolicyReference ( ) , POLICYREFERENCE_B...
public class LineChartRenderer { /** * implementing point styles . */ private void drawPoints ( Canvas canvas , Line line , int lineIndex , int mode ) { } }
pointPaint . setColor ( line . getPointColor ( ) ) ; int valueIndex = 0 ; for ( PointValue pointValue : line . getValues ( ) ) { int pointRadius = ChartUtils . dp2px ( density , line . getPointRadius ( ) ) ; final float rawX = computator . computeRawX ( pointValue . getX ( ) ) ; final float rawY = computator . computeR...
public class JapaneseEra { /** * Returns the end date of the era . * @ return the end date */ LocalDate endDate ( ) { } }
int ordinal = ordinal ( eraValue ) ; JapaneseEra [ ] eras = values ( ) ; if ( ordinal >= eras . length - 1 ) { return LocalDate . MAX ; } return eras [ ordinal + 1 ] . startDate ( ) . minusDays ( 1 ) ;
public class CmsSecurityManager { /** * Sets a new parent - group for an already existing group . < p > * @ param context the current request context * @ param groupName the name of the group that should be written * @ param parentGroupName the name of the parent group to set , * or < code > null < / code > if ...
CmsDbContext dbc = m_dbContextFactory . getDbContext ( context ) ; try { checkRole ( dbc , CmsRole . ACCOUNT_MANAGER . forOrgUnit ( getParentOrganizationalUnit ( groupName ) ) ) ; m_driverManager . setParentGroup ( dbc , CmsOrganizationalUnit . removeLeadingSeparator ( groupName ) , CmsOrganizationalUnit . removeLeadin...
public class VoiceApi { /** * Send digits as DTMF * Send DTMF digits to the specified call . You can send DTMF digits individually with multiple requests or together with multiple digits in one request . * @ param id The connection ID of the call . ( required ) * @ param sendDTMFData ( required ) * @ return Api...
ApiResponse < ApiSuccessResponse > resp = sendDTMFWithHttpInfo ( id , sendDTMFData ) ; return resp . getData ( ) ;
public class ObjectClassificationImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ public void setObjClass ( Integer newObjClass ) { } }
Integer oldObjClass = objClass ; objClass = newObjClass ; if ( eNotificationRequired ( ) ) eNotify ( new ENotificationImpl ( this , Notification . SET , AfplibPackage . OBJECT_CLASSIFICATION__OBJ_CLASS , oldObjClass , objClass ) ) ;
public class AbstractRStarTree { /** * Reinserts the specified node at the specified level . * @ param node the node to be reinserted * @ param path the path to the node * @ param offs the nodes indexes to reinsert */ public void reInsert ( N node , IndexTreePath < E > path , int [ ] offs ) { } }
final int depth = path . getPathCount ( ) ; long [ ] remove = BitsUtil . zero ( node . getCapacity ( ) ) ; List < E > reInsertEntries = new ArrayList < > ( offs . length ) ; for ( int i = 0 ; i < offs . length ; i ++ ) { reInsertEntries . add ( node . getEntry ( offs [ i ] ) ) ; BitsUtil . setI ( remove , offs [ i ] ) ...
public class MicronautConsole { /** * Replacement for AntBuilder . input ( ) to eliminate dependency of GrailsScriptRunner on the Ant libraries . * Prints a message and list of valid responses , then returns whatever the user enters * ( once they press & lt ; return & gt ; ) . If the user enters something that is n...
if ( validResponses == null ) { return userInput ( message ) ; } String question = createQuestion ( message , validResponses ) ; String response = userInput ( question ) ; for ( String validResponse : validResponses ) { if ( validResponse . equalsIgnoreCase ( response ) ) { return response ; } } cursorMove = 0 ; return...
public class ListViewColumn { /** * Creates the list of { @ link ListViewColumn } s to be used for newly created { @ link ListView } s and their likes . * @ see ListView # initColumns ( ) * @ since 2.37 */ public static List < ListViewColumn > createDefaultInitialColumnList ( Class < ? extends View > context ) { } ...
return createDefaultInitialColumnList ( DescriptorVisibilityFilter . applyType ( context , ListViewColumn . all ( ) ) ) ;
public class LiveOutputsInner { /** * Get Live Output . * Gets a Live Output . * @ param resourceGroupName The name of the resource group within the Azure subscription . * @ param accountName The Media Services account name . * @ param liveEventName The name of the Live Event . * @ param liveOutputName The na...
return getWithServiceResponseAsync ( resourceGroupName , accountName , liveEventName , liveOutputName ) . toBlocking ( ) . single ( ) . body ( ) ;
public class URLService { /** * Agent will use this method , the baseUrl will be injected from config xml in agent side . * This is used to fix security issues with the agent uploading artifacts when security is enabled . */ public String getPropertiesUrl ( JobIdentifier jobIdentifier , String propertyName ) { } }
return format ( "%s/%s/%s/%s" , baseRemotingURL , "remoting" , "properties" , jobIdentifier . propertyLocator ( propertyName ) ) ;
public class TrieBuilder { /** * Checks if the character belongs to a zero block in the trie * @ param ch codepoint which data is to be retrieved * @ return true if ch is in the zero block */ public boolean isInZeroBlock ( int ch ) { } }
// valid , uncompacted trie and valid c ? if ( m_isCompacted_ || ch > UCharacter . MAX_VALUE || ch < UCharacter . MIN_VALUE ) { return true ; } return m_index_ [ ch >> SHIFT_ ] == 0 ;
public class JSONParser { /** * Parse a quoted / escaped JSON string . * < pre > * String ← S ? [ " ] ( [ ^ " \ U + 0000 - U + 001F ] / Escape ) * [ " ] S ? * Escape ← [ \ ] ( [ " / \ b f n r t ] / UnicodeEscape ) * UnicodeEscape ← " u " [ 0-9A - Fa - f ] { 4} * < / pre > * @ return the char sequence * @ ...
skipWhitespace ( ) ; if ( peek ( ) != '"' ) { return null ; } next ( ) ; final int startIdx = getPosition ( ) ; // Fast path boolean hasEscape = false ; while ( hasMore ( ) ) { final char c = getc ( ) ; if ( c == '\\' ) { switch ( getc ( ) ) { case 'b' : case 'f' : case 'n' : case 'r' : case 't' : case '\'' : case '"' ...
public class AmazonInspectorClient { /** * Enables the process of sending Amazon Simple Notification Service ( SNS ) notifications about a specified event to * a specified SNS topic . * @ param subscribeToEventRequest * @ return Result of the SubscribeToEvent operation returned by the service . * @ throws Inter...
request = beforeClientExecution ( request ) ; return executeSubscribeToEvent ( request ) ;
public class MappedFieldMetaData { /** * Determines the relative or absolute JCR path of a field . * The path is derived from either the field name ( this is the default ) * or from an explicit { @ link io . neba . api . annotations . Path } annotation . */ private ResourcePaths . ResourcePath getPathInternal ( ) {...
String resolvedPath ; if ( isPathAnnotationPresent ( ) ) { Path path = this . annotations . get ( Path . class ) ; if ( isBlank ( path . value ( ) ) ) { throw new IllegalArgumentException ( "The value of the @" + Path . class . getSimpleName ( ) + " annotation on " + field + " must not be empty" ) ; } resolvedPath = pa...
public class DayPartitionBuilder { /** * / * [ deutsch ] * < p > F & uuml ; gt eine Regel hinzu , die einen speziellen Kalendertag zerlegt . < / p > * < p > Diese Methode kann mehrmals f & uuml ; r das gleiche Datum aufgerufen werden , um mehr als einen * Tagesabschnitt zu definieren . < / p > * @ param special...
if ( specialDay == null ) { throw new NullPointerException ( "Missing special calendar date." ) ; } try { ClockInterval p = partition . toCanonical ( ) ; if ( ! p . isEmpty ( ) ) { List < ChronoInterval < PlainTime > > ps = this . exceptionRules . get ( specialDay ) ; if ( ps == null ) { ps = new ArrayList < > ( 5 ) ; ...
public class ApkBuilder { /** * Seals the APK , and signs it if necessary . * @ throws ApkCreationException * @ throws ApkCreationException if an error occurred * @ throws SealedApkException if the APK is already sealed . */ public void sealApk ( ) throws ApkCreationException , SealedApkException { } }
if ( mIsSealed ) { throw new SealedApkException ( "APK is already sealed" ) ; } // close and sign the application package . try { mBuilder . close ( ) ; mIsSealed = true ; } catch ( Exception e ) { throw new ApkCreationException ( e , "Failed to seal APK" ) ; } finally { mBuilder . cleanUp ( ) ; }
public class FpgaImageAttribute { /** * The load permissions . * < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use * { @ link # setLoadPermissions ( java . util . Collection ) } or { @ link # withLoadPermissions ( java . util . Collection ) } if you * want to override the e...
if ( this . loadPermissions == null ) { setLoadPermissions ( new com . amazonaws . internal . SdkInternalList < LoadPermission > ( loadPermissions . length ) ) ; } for ( LoadPermission ele : loadPermissions ) { this . loadPermissions . add ( ele ) ; } return this ;
public class ManagementLocksInner { /** * Deletes the management lock at the subscription level . * To delete management locks , you must have access to Microsoft . Authorization / * or Microsoft . Authorization / locks / * actions . Of the built - in roles , only Owner and User Access Administrator are granted those...
if ( lockName == null ) { throw new IllegalArgumentException ( "Parameter lockName is required and cannot be null." ) ; } if ( this . client . subscriptionId ( ) == null ) { throw new IllegalArgumentException ( "Parameter this.client.subscriptionId() is required and cannot be null." ) ; } if ( this . client . apiVersio...
public class GroupService { /** * Create snapshot of servers groups * @ param expirationDays expiration days ( must be between 1 and 10) * @ param groups groups references list * @ return OperationFuture wrapper for Server list */ public OperationFuture < List < Server > > createSnapshot ( Integer expirationDays ...
return serverService ( ) . createSnapshot ( expirationDays , getServerSearchCriteria ( groups ) ) ;
public class MtasSolrComponentStats { /** * ( non - Javadoc ) * @ see * mtas . solr . handler . component . util . MtasSolrComponent # prepare ( org . apache . solr . * handler . component . ResponseBuilder , * mtas . codec . util . CodecComponent . ComponentFields ) */ public void prepare ( ResponseBuilder rb ...
if ( rb . req . getParams ( ) . getBool ( PARAM_MTAS_STATS_POSITIONS , false ) ) { preparePositions ( rb , mtasFields ) ; } if ( rb . req . getParams ( ) . getBool ( PARAM_MTAS_STATS_TOKENS , false ) ) { prepareTokens ( rb , mtasFields ) ; } if ( rb . req . getParams ( ) . getBool ( PARAM_MTAS_STATS_SPANS , false ) ) {...
public class ConversationProxy { /** * region Payload */ public void addPayload ( final SurveyResponsePayload payload ) { } }
dispatchOnConversationQueue ( new DispatchTask ( ) { @ Override protected void execute ( ) { conversation . addPayload ( payload ) ; } } ) ;
public class Jar { /** * Adds an entry to this JAR . * @ param path the entry ' s path within the JAR * @ param file the path of the file to add as an entry * @ return { @ code this } */ public Jar addEntry ( String path , String file ) throws IOException { } }
try ( FileInputStream fos = new FileInputStream ( file ) ) { return addEntry ( path , fos ) ; }
public class InternalXtypeParser { /** * InternalXtype . g : 208:1 : entryRuleJvmUpperBound : ruleJvmUpperBound EOF ; */ public final void entryRuleJvmUpperBound ( ) throws RecognitionException { } }
try { // InternalXtype . g : 209:1 : ( ruleJvmUpperBound EOF ) // InternalXtype . g : 210:1 : ruleJvmUpperBound EOF { if ( state . backtracking == 0 ) { before ( grammarAccess . getJvmUpperBoundRule ( ) ) ; } pushFollow ( FOLLOW_1 ) ; ruleJvmUpperBound ( ) ; state . _fsp -- ; if ( state . failed ) return ; if ( state ....
public class OWLResultSetTableModel { /** * Fetch all the tuples returned by the result set . */ public List < String [ ] > getTabularData ( ) throws OWLException , InterruptedException { } }
if ( tabularData == null ) { tabularData = new ArrayList < > ( ) ; String [ ] columnName = results . getSignature ( ) . toArray ( new String [ numcols ] ) ; // Append the column names tabularData . add ( columnName ) ; while ( this . isFetching ) { Thread . sleep ( 10 ) ; } if ( stopFetching ) return null ; // Append f...
public class FSDirectory { /** * Search the given block from the file and return the block index */ int getBlockIndex ( INodeFile inode , Block blk , String file ) throws IOException { } }
if ( inode == null ) { throw new IOException ( "inode for file " + file + " is null" ) ; } readLock ( ) ; try { return inode . getBlockIndex ( blk , file ) ; } finally { readUnlock ( ) ; }
public class ConvertUtil { /** * Same as { @ linkplain ConvertUtil # toInteger ( Object ) } but does not throw an exception * if the conversion could not be done . * @ param value * @ param defaultValue * @ return */ public static Integer toInteger ( Object value , Integer defaultValue ) { } }
try { return toInteger ( value ) ; } catch ( Exception e ) { return defaultValue ; }
public class RegisterUtils { /** * returns the register used in a load operation * @ param dbc * the dismantle byte code parsing the class * @ param seen * the opcode of the load * @ return the register stored into */ public static int getLoadReg ( DismantleBytecode dbc , int seen ) { } }
if ( ( seen == Const . ALOAD ) || ( seen == Const . ILOAD ) || ( seen == Const . LLOAD ) || ( seen == Const . FLOAD ) || ( seen == Const . DLOAD ) ) { return dbc . getRegisterOperand ( ) ; } if ( OpcodeUtils . isILoad ( seen ) ) { return seen - Const . ILOAD_0 ; } else if ( OpcodeUtils . isLLoad ( seen ) ) { return see...
public class AbstractBindModule { /** * Generate a list property * List singleton bean references with list ( A . class , B . class ) or * list ( ref ( " someBeanId " ) , C . class ) . < br > * List simple values with list ( " strValue1 " , " strValue2 " ) * @ param datas */ protected final List < ? > list ( Ob...
List < Object > items = CollectUtils . newArrayList ( datas . length ) ; for ( Object obj : datas ) { if ( obj instanceof Class < ? > ) { items . add ( buildInnerReference ( ( Class < ? > ) obj ) ) ; } else { items . add ( obj ) ; } } return items ;
public class Validate { /** * Checks that string is not null and not empty and it represents a path to a valid directory * @ param string * The path to check * @ param message * The exception message * @ throws ConfigurationException * Thrown if string is empty , null or it does not represent a path the a v...
if ( string == null || string . length ( ) == 0 || new File ( string ) . isDirectory ( ) == false ) { throw new ConfigurationException ( message ) ; }
public class OUser { /** * Checks if a rule was defined for the user . * @ param iResource * Requested resource * @ return True is a rule is defined , otherwise false */ public boolean isRuleDefined ( final String iResource ) { } }
for ( ORole r : roles ) if ( r . hasRule ( iResource ) ) return true ; return false ;
public class Node { /** * Returns the textual representation of the current node and all its child nodes . * @ return the text value of the node including child text */ public String text ( ) { } }
if ( value instanceof String ) { return ( String ) value ; } if ( value instanceof NodeList ) { return ( ( NodeList ) value ) . text ( ) ; } if ( value instanceof Collection ) { Collection coll = ( Collection ) value ; String previousText = null ; StringBuilder sb = null ; for ( Object child : coll ) { String childText...
public class RestyAuthenticator { /** * Add or replace an authentication for a root URL aka site . * @ param aRootUrl * @ param login * @ param pwd */ public void addSite ( URI aRootUrl , String login , char [ ] pwd ) { } }
String rootUri = aRootUrl . normalize ( ) . toString ( ) ; boolean replaced = false ; // check if we already have a login / password for the root uri for ( Site site : sites ) { if ( site . root . equals ( rootUri ) ) { // TODO synchronisation site . login = login ; site . pwd = pwd ; replaced = true ; break ; } } if (...
public class Assert { /** * 错误的下标时显示的消息 * @ param index 下标 * @ param size 长度 * @ param desc 异常时的消息模板 * @ param params 参数列表 * @ return 消息 */ private static String badIndexMsg ( int index , int size , String desc , Object ... params ) { } }
if ( index < 0 ) { return StrUtil . format ( "{} ({}) must not be negative" , StrUtil . format ( desc , params ) , index ) ; } else if ( size < 0 ) { throw new IllegalArgumentException ( "negative size: " + size ) ; } else { // index > = size return StrUtil . format ( "{} ({}) must be less than size ({})" , StrUtil . f...
public class AbstractStereo { /** * apply the inverse of a permutation */ protected static < T > T [ ] invapply ( T [ ] src , int [ ] perm ) { } }
T [ ] res = src . clone ( ) ; for ( int i = 0 ; i < src . length ; i ++ ) res [ i ] = src [ perm [ i ] ] ; return res ;
public class AiMesh { /** * This method is used by JNI . Do not call or modify . < p > * Allocates byte buffers * @ param numVertices the number of vertices in the mesh * @ param numFaces the number of faces in the mesh * @ param optimizedFaces set true for optimized face representation * @ param faceBufferSi...
/* * the allocated buffers are native order direct byte buffers , so they * can be passed directly to LWJGL or similar graphics APIs */ /* ensure face optimization is possible */ if ( optimizedFaces && ! isPureTriangle ( ) ) { throw new IllegalArgumentException ( "mesh is not purely triangular" ) ; } m_numVertices = ...
public class MethodBuilder { /** * getParcelObject method */ private void addGetParcelObject ( TypeSpec . Builder classBuilder ) { } }
MethodSpec . Builder methodBuilder = MethodSpec . methodBuilder ( "getParcelerObject" ) . addModifiers ( Modifier . PRIVATE ) . returns ( Object . class ) . addParameter ( String . class , "pClassName" ) . addParameter ( ClassName . get ( "android.os" , "Parcel" ) , "data" ) . beginControlFlow ( "try" ) . addStatement ...
public class ImplRectifyImageOps_F32 { /** * Internal function which applies the rectification adjustment to an uncalibrated stereo pair */ private static void adjustUncalibrated ( FMatrixRMaj rectifyLeft , FMatrixRMaj rectifyRight , RectangleLength2D_F32 bound , float scale ) { } }
// translation float deltaX = - bound . x0 * scale ; float deltaY = - bound . y0 * scale ; // adjustment matrix SimpleMatrix A = new SimpleMatrix ( 3 , 3 , true , new float [ ] { scale , 0 , deltaX , 0 , scale , deltaY , 0 , 0 , 1 } ) ; SimpleMatrix rL = SimpleMatrix . wrap ( rectifyLeft ) ; SimpleMatrix rR = SimpleMat...
public class MultiScopeRecoveryLog { /** * Informs the RLS that any outstanding recovery process for the recovery log is * complete . Client services may issue this call to give the RLS an opportunity * to optomize log access by performing a keypoint operation . Client services do * not have to issue this call . ...
if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "recoveryComplete" , new java . lang . Object [ ] { RLSUtils . toHexString ( serviceData , RLSUtils . MAX_DISPLAY_BYTES ) , this } ) ; // If this recovery log instance has been marked as incompatible then throw an exception // accordingly . if ( incompatible ( ) ) { if (...
public class JTextFieldDateEditor { /** * ( non - Javadoc ) * @ see java . awt . Component # setLocale ( java . util . Locale ) */ public void setLocale ( Locale locale ) { } }
if ( locale == getLocale ( ) || ignoreDatePatternChange ) { return ; } super . setLocale ( locale ) ; dateFormatter = ( SimpleDateFormat ) DateFormat . getDateInstance ( DateFormat . MEDIUM , locale ) ; setToolTipText ( dateFormatter . toPattern ( ) ) ; setDate ( date , false ) ; doLayout ( ) ;
public class ImageReaderBase { /** * Convenience method to make sure image index is within bounds . * @ param index the image index * @ throws java . io . IOException if an error occurs during reading * @ throws IndexOutOfBoundsException if not { @ code minIndex < = index < numImages } */ protected void checkBoun...
assertInput ( ) ; if ( index < getMinIndex ( ) ) { throw new IndexOutOfBoundsException ( "index < minIndex" ) ; } int numImages = getNumImages ( false ) ; if ( numImages != - 1 && index >= numImages ) { throw new IndexOutOfBoundsException ( "index >= numImages (" + index + " >= " + numImages + ")" ) ; }
public class GLINERGImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ @ Override public void eSet ( int featureID , Object newValue ) { } }
switch ( featureID ) { case AfplibPackage . GLINERG__XPOS : setXPOS ( ( Integer ) newValue ) ; return ; case AfplibPackage . GLINERG__YPOS : setYPOS ( ( Integer ) newValue ) ; return ; } super . eSet ( featureID , newValue ) ;
public class Label { /** * Filter out any color tags from the specified text . */ public static String filterColors ( String txt ) { } }
if ( txt == null ) return null ; return COLOR_PATTERN . matcher ( txt ) . replaceAll ( "" ) ;
public class StreamingEndpointsInner { /** * Update StreamingEndpoint . * Updates a existing StreamingEndpoint . * @ param resourceGroupName The name of the resource group within the Azure subscription . * @ param accountName The Media Services account name . * @ param streamingEndpointName The name of the Stre...
return updateWithServiceResponseAsync ( resourceGroupName , accountName , streamingEndpointName , parameters ) . toBlocking ( ) . last ( ) . body ( ) ;
public class PELoader { /** * FIXME */ private OptionalHeader reloadOptionalHeader ( PESignature pesig , MemoryMappedPE mmBytes , PEData data ) throws IOException { } }
logger . info ( "reloading optional header" ) ; // offset right after the eCOFF File Header long offset = pesig . getOffset ( ) + PESignature . PE_SIG . length + COFFFileHeader . HEADER_SIZE ; logger . info ( "Optional Header offset: " + offset ) ; int size = getOptHeaderSize ( offset ) ; // read bytes and construct he...
public class JDBCConnection { /** * Resets this connection so it can be used again . Used when connections are * returned to a connection pool . * @ throws SQLException if a database access error occurs */ public void reset ( ) throws SQLException { } }
try { this . sessionProxy . resetSession ( ) ; } catch ( HsqlException e ) { throw Util . sqlException ( ErrorCode . X_08006 , e . getMessage ( ) , e ) ; }
public class AbstractKubernetesCommand { /** * Reads without labels from expression string . * @ param labelExpression * @ param context * @ return */ protected Map < String , String > getWithoutLabels ( String labelExpression , TestContext context ) { } }
Map < String , String > labels = new HashMap < > ( ) ; Set < String > values = StringUtils . commaDelimitedListToSet ( labelExpression ) ; for ( String item : values ) { if ( item . contains ( "!=" ) ) { labels . put ( context . replaceDynamicContentInString ( item . substring ( 0 , item . indexOf ( "!=" ) ) ) , contex...
public class CreateDirectoryRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( CreateDirectoryRequest createDirectoryRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( createDirectoryRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( createDirectoryRequest . getName ( ) , NAME_BINDING ) ; protocolMarshaller . marshall ( createDirectoryRequest . getSchemaArn ( ) , SCHEMAARN_BINDING ) ; } catch ...
public class LocalNode { /** * Return true when one of the following conditions is met < br > * < br > * 1 . ConfigProperty for driverBinary is specified and not blank or null . < br > * 2 . System Property which Selenium uses to find driverBinary is present . < br > * 3 . driverBinary exists in the current wor...
if ( StringUtils . isBlank ( Config . getConfigProperty ( property ) ) && System . getProperty ( systemProperty ) == null ) { // check the CWD and PATH for the driverBinary String location = new ExecutableFinder ( ) . find ( driverBinary . replace ( ".exe" , "" ) ) ; return ( location != null ) ; } return true ;
public class RedisJobStore { /** * Pause all of the < code > { @ link org . quartz . Job } s < / code > in the given * group - by pausing all of their < code > Trigger < / code > s . * The JobStore should " remember " that the group is paused , and impose the * pause on any new jobs that are added to the group wh...
return doWithLock ( new LockCallback < Collection < String > > ( ) { @ Override public Collection < String > doWithLock ( JedisCommands jedis ) throws JobPersistenceException { return storage . pauseJobs ( groupMatcher , jedis ) ; } } , "Could not pause jobs." ) ;
public class ConstantPoolChecker2 { static References getReferences ( byte [ ] bytes ) { } }
ConstantPoolChecker2 cpc2 = new ConstantPoolChecker2 ( bytes ) ; return new References ( cpc2 . slashedclassname , cpc2 . referencedClasses , cpc2 . referencedMethods ) ;
public class GrpcBlockingStream { /** * Sends a request . Will not wait for the stream to be ready . * @ param request the request * @ throws IOException if any error occurs */ public void send ( ReqT request ) throws IOException { } }
if ( mClosed || mCanceled || mClosedFromRemote ) { throw new CancelledException ( formatErrorMessage ( "Failed to send request %s: stream is already closed or canceled." , request ) ) ; } try ( LockResource lr = new LockResource ( mLock ) ) { checkError ( ) ; } mRequestObserver . onNext ( request ) ;
public class CmsContainerpageService { /** * Returns the sub - elements of this inherit container resource . < p > * @ param resource the inherit container resource * @ param locale the requested locale * @ param uriParam the current URI * @ return the sub - elements * @ throws CmsException if something goes ...
CmsObject cms = getCmsObject ( ) ; cms . getRequestContext ( ) . setLocale ( locale ) ; CmsInheritanceReferenceParser parser = new CmsInheritanceReferenceParser ( cms ) ; parser . parse ( resource ) ; CmsInheritanceReference ref = parser . getReference ( locale ) ; if ( ref == null ) { // new inheritance reference , re...
public class InstanceAdminClient { /** * Lists the supported instance configurations for a given project . * < p > Sample code : * < pre > < code > * try ( InstanceAdminClient instanceAdminClient = InstanceAdminClient . create ( ) ) { * ProjectName parent = ProjectName . of ( " [ PROJECT ] " ) ; * for ( Insta...
ListInstanceConfigsRequest request = ListInstanceConfigsRequest . newBuilder ( ) . setParent ( parent ) . build ( ) ; return listInstanceConfigs ( request ) ;
public class MarkupSelectorFilter { /** * Processing Instruction handling */ boolean matchProcessingInstruction ( final boolean blockMatching , final int markupLevel , final int markupBlockIndex ) { } }
checkMarkupLevel ( markupLevel ) ; if ( this . markupSelectorItem . anyLevel ( ) || markupLevel == 0 || ( this . prev != null && this . prev . matchedMarkupLevels [ markupLevel - 1 ] ) ) { // This text has not matched yet , but might match , so we should check this . matchesThisLevel = this . markupSelectorItem . match...
public class NuProcessBuilder { /** * Spawn the child process with the configured commands , environment , and * { @ link NuProcessHandler } . * @ return a { @ link NuProcess } instance or { @ code null } if there is an * immediately detectable launch failure */ public NuProcess start ( ) { } }
if ( processListener == null ) { throw new IllegalArgumentException ( "NuProcessHandler not specified" ) ; } String [ ] env = new String [ environment . size ( ) ] ; int i = 0 ; for ( Entry < String , String > entrySet : environment . entrySet ( ) ) { env [ i ++ ] = entrySet . getKey ( ) + "=" + entrySet . getValue ( )...
public class Matrix4x3f { /** * Set this matrix to a rotation transformation about the X axis . * When used with a right - handed coordinate system , the produced rotation will rotate a vector * counter - clockwise around the rotation axis , when viewing along the negative axis direction towards the origin . * Wh...
float sin , cos ; if ( ang == ( float ) Math . PI || ang == - ( float ) Math . PI ) { cos = - 1.0f ; sin = 0.0f ; } else if ( ang == ( float ) Math . PI * 0.5f || ang == - ( float ) Math . PI * 1.5f ) { cos = 0.0f ; sin = 1.0f ; } else if ( ang == ( float ) - Math . PI * 0.5f || ang == ( float ) Math . PI * 1.5f ) { co...
public class DefaultDataEditorWidget { /** * Executes filter and fills table in specific manner : * < ul > * < li > set baseCriteria if needed < / li > * < li > set searchCriteria on filterForm < / li > * < li > set searchCriteria on worker < / li > * < li > pass parameter map to worker < / li > * < li > la...
if ( listWorker == null ) { if ( dataProvider . supportsBaseCriteria ( ) ) { dataProvider . setBaseCriteria ( getBaseCriteria ( ) ) ; } StatusBar statusBar = getApplicationConfig ( ) . windowManager ( ) . getActiveWindow ( ) . getStatusBar ( ) ; statusBar . getProgressMonitor ( ) . taskStarted ( getApplicationConfig ( ...
public class CmsResourceImportData { /** * Gets the content . < p > * @ return the content , or null if there is no content */ public byte [ ] getContent ( ) { } }
if ( m_contentFile == null ) { return null ; } try { return CmsFileUtil . readFile ( m_contentFile ) ; } catch ( Exception e ) { throw new RuntimeException ( e ) ; }
public class NFRule { /** * Creates one or more rules based on the description passed in . * @ param description The description of the rule ( s ) . * @ param owner The rule set containing the new rule ( s ) . * @ param predecessor The rule that precedes the new one ( s ) in " owner " ' s * rule list * @ para...
// we know we ' re making at least one rule , so go ahead and // new it up and initialize its basevalue and divisor // ( this also strips the rule descriptor , if any , off the // description string ) NFRule rule1 = new NFRule ( ownersOwner , description ) ; description = rule1 . ruleText ; // check the description to ...
public class StaticConnectionProvider { /** * from ConnectionProvider */ public void connectionFailed ( String ident , boolean readOnly , Connection conn , SQLException error ) { } }
String mapkey = ident + ":" + readOnly ; Mapping conmap = _idents . get ( mapkey ) ; if ( conmap == null ) { log . warning ( "Unknown connection failed!?" , "key" , mapkey ) ; } else { conmap . closeConnection ( ident ) ; }
public class ClassTranslator { /** * Create a new ClassFile from { @ code cf } , such that for all entries * { @ code k & nbsp ; - \ & gt ; & nbsp ; v } in { @ code translations } , * each occurrence of { @ code k } in { @ code cf } will be replaced by { @ code v } . * in * @ param cf the class file to be proce...
ClassFile cf2 = ( ClassFile ) translations . get ( cf ) ; if ( cf2 == null ) { ConstantPool constant_pool2 = translate ( cf . constant_pool , translations ) ; Field [ ] fields2 = translate ( cf . fields , cf . constant_pool , translations ) ; Method [ ] methods2 = translateMethods ( cf . methods , cf . constant_pool , ...
public class TraceComponent { /** * Count the number of non - null non - duplicate elements in an array , and copy * those elements to an output array if provided . * @ param in the input array * @ param out an output array , or null to count rather than copying * @ return the number of non - null non - duplica...
int count = 0 ; outer : for ( int i = 0 ; i < in . length ; i ++ ) { if ( in [ i ] != null ) { for ( int j = 0 ; j < i ; j ++ ) if ( in [ i ] . equals ( in [ j ] ) ) continue outer ; if ( out != null ) out [ count ] = in [ i ] ; count ++ ; } } return count ;
public class XHTMLText { /** * Appends a tag that indicates that a body section begins . * @ param style the XHTML style of the body * @ param lang the language of the body * @ return this . */ private XHTMLText appendOpenBodyTag ( String style , String lang ) { } }
text . halfOpenElement ( Message . BODY ) ; text . xmlnsAttribute ( NAMESPACE ) ; text . optElement ( STYLE , style ) ; text . xmllangAttribute ( lang ) ; text . rightAngleBracket ( ) ; return this ;
public class GoogleNavigationDrawer { /** * Reload Application data from Account Information */ public void notifyAccountDataChanged ( ) { } }
switch ( accountManager . size ( ) ) { case 1 : this . setFirstAccountPhoto ( currentAccount . getCircularPhoto ( ) ) ; this . setDrawerBackground ( currentAccount . getBackground ( ) ) ; this . setUsername ( currentAccount . getTitle ( ) ) ; this . setUserEmail ( currentAccount . getSubTitle ( ) ) ; default : }
public class DispatchQueue { /** * Creates a background queue with specified < code > name < / code > and dispatch type . */ public static DispatchQueue createBackgroundQueue ( String name , DispatchQueueType type ) { } }
if ( type == DispatchQueueType . Serial ) { return new SerialDispatchQueue ( name ) ; } if ( type == DispatchQueueType . Concurrent ) { return new ConcurrentDispatchQueue ( name ) ; } throw new IllegalArgumentException ( "Unexpected queue type: " + type ) ;
public class SessionContext { /** * Keeps track of J2EE names of listeners . We only do this for global * sessions . * In this case , one Enterprise ( J2EE ) app may be stopped , so we need to stop * listeners * for that app . */ private void addToJ2eeNameList ( String j2eeName , int size , ArrayList listenerJ2...
int start = listenerJ2eeNames . size ( ) ; int end = start + size ; if ( com . ibm . ejs . ras . TraceComponent . isAnyTracingEnabled ( ) && LoggingUtil . SESSION_LOGGER_CORE . isLoggable ( Level . FINE ) ) { StringBuffer sb = new StringBuffer ( "starting at " ) . append ( start ) . append ( " going to " ) . append ( e...
public class PortletRequestContextImpl { /** * Called by { @ link PortletServlet } after the cross context dispatch but before the portlet * invocation * @ see org . apache . pluto . container . PortletRequestContext # init ( javax . portlet . PortletConfig , * javax . servlet . ServletContext , javax . servlet ....
Assert . notNull ( portletConfig , "portletConfig cannot be null" ) ; Assert . notNull ( servletContext , "servletContext cannot be null" ) ; super . init ( servletRequest , servletResponse ) ; this . portletConfig = portletConfig ; this . servletContext = servletContext ;
public class KamImpl { /** * { @ inheritDoc } */ @ Override public Collection < KamEdge > getEdges ( EdgeFilter filter ) { } }
Set < KamEdge > kamEdges = new LinkedHashSet < KamEdge > ( ) ; for ( KamEdge kamEdge : edgeIdMap . keySet ( ) ) { // Check for an edge filter if ( null != filter ) { if ( ! filter . accept ( kamEdge ) ) { continue ; } } kamEdges . add ( kamEdge ) ; } return kamEdges ;
public class ListTypesRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( ListTypesRequest listTypesRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( listTypesRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( listTypesRequest . getApiId ( ) , APIID_BINDING ) ; protocolMarshaller . marshall ( listTypesRequest . getFormat ( ) , FORMAT_BINDING ) ; protocolMarshaller . marshall ...
public class ResourceGroovyMethods { /** * Append the text supplied by the Writer at the end of the File without writing a BOM . * @ param file a File * @ param reader the Reader supplying the text to append at the end of the File * @ throws IOException if an IOException occurs . * @ since 2.3 */ public static ...
append ( file , reader , false ) ;
public class ServerContext { /** * Sets the state last voted for candidate . * @ param candidate The candidate that was voted for . * @ return The Raft context . */ ServerContext setLastVotedFor ( int candidate ) { } }
// If we ' ve already voted for another candidate in this term then the last voted for candidate cannot be overridden . Assert . stateNot ( lastVotedFor != 0 && candidate != 0L , "Already voted for another candidate" ) ; ServerMember member = cluster . member ( candidate ) ; Assert . state ( member != null , "unknown c...
public class N { /** * Returns { @ code true } if the two specified arrays have no elements in common . * @ param a * @ param b * @ return { @ code true } if the two specified arrays have no elements in common . * @ see Collections # disjoint ( Collection , Collection ) */ public static boolean disjoint ( final...
if ( isNullOrEmpty ( c1 ) || isNullOrEmpty ( c2 ) ) { return true ; } if ( c1 instanceof Set || ( c2 instanceof Set == false && c1 . size ( ) > c2 . size ( ) ) ) { for ( Object e : c2 ) { if ( c1 . contains ( e ) ) { return false ; } } } else { for ( Object e : c1 ) { if ( c2 . contains ( e ) ) { return false ; } } } r...
public class RandomMatrices_DDRM { /** * Creates a random matrix which will have the provided singular values . The length of sv * is assumed to be the rank of the matrix . This can be useful for testing purposes when one * needs to ensure that a matrix is not singular but randomly generated . * @ param numRows N...
DMatrixRMaj U , V , S ; // speed it up in compact format if ( numRows > numCols ) { U = RandomMatrices_DDRM . orthogonal ( numRows , numCols , rand ) ; V = RandomMatrices_DDRM . orthogonal ( numCols , numCols , rand ) ; S = new DMatrixRMaj ( numCols , numCols ) ; } else { U = RandomMatrices_DDRM . orthogonal ( numRows ...
public class ADT { /** * Splitting a leaf node by extending the trace leading into the node to split . * @ param nodeToSplit * the leaf node to extends * @ param distinguishingSuffix * the input sequence that splits the hypothesis state of the leaf to split and the new node . The current * trace leading into ...
if ( ! ADTUtil . isLeafNode ( nodeToSplit ) ) { throw new IllegalArgumentException ( "Node to split is not a leaf node" ) ; } if ( ! ( distinguishingSuffix . length ( ) == oldOutput . length ( ) && oldOutput . length ( ) == newOutput . length ( ) ) ) { throw new IllegalArgumentException ( "Distinguishing suffixes and o...
public class Matrix3f { /** * Apply an oblique projection transformation to this matrix with the given values for < code > a < / code > and * < code > b < / code > and store the result in < code > dest < / code > . * If < code > M < / code > is < code > this < / code > matrix and < code > O < / code > the oblique t...
dest . m00 = m00 ; dest . m01 = m01 ; dest . m02 = m02 ; dest . m10 = m10 ; dest . m11 = m11 ; dest . m12 = m12 ; dest . m20 = m00 * a + m10 * b + m20 ; dest . m21 = m01 * a + m11 * b + m21 ; dest . m22 = m02 * a + m12 * b + m22 ; return dest ;