id stringlengths 11 16 | language stringclasses 2
values | question stringlengths 13 844 | answer stringlengths 1 900 | code stringlengths 162 27.4k | code_original stringlengths 162 26k | code_word_count int64 51 5.96k |
|---|---|---|---|---|---|---|
java-test-9686 | java | What does the code count ? | the number of distinct lines in a string | protected int count Lines In String ( final String string To Search , final boolean count Blank Lines ) { assert ( string To Search != null ) ; int length = string To Search . length ( ) ; int count = NUM ; char character = NUM ; boolean found Non Space Char = BOOL ; for ( int i = NUM ; i < length ; i ++ ) { character ... | protected int countLinesInString ( final String stringToSearch , final boolean countBlankLines ) { assert ( stringToSearch != null ) ; int length = stringToSearch . length ( ) ; int count = _NUM ; char character = _NUM ; boolean foundNonSpaceChar = _BOOL ; for ( int i = _NUM ; i < length ; i ++ ) { character = stringTo... | 203 |
java-test-9687 | java | What does the code make ? | a shallow copy of this collection | public Matched Event Map Impl shallow Copy ( ) { if ( matches . length == NUM ) { return this ; } Object [ ] copy = new Object [ matches . length ] ; if ( matches . length > NUM ) { System . arraycopy ( matches , NUM , copy , NUM , matches . length ) ; } else { copy [ NUM ] = matches [ NUM ] ; } return new Matched Even... | public MatchedEventMapImpl shallowCopy ( ) { if ( matches . length == _NUM ) { return this ; } Object [ ] copy = new Object [ matches . length ] ; if ( matches . length > _NUM ) { System . arraycopy ( matches , _NUM , copy , _NUM , matches . length ) ; } else { copy [ _NUM ] = matches [ _NUM ] ; } return new MatchedEve... | 89 |
java-test-9688 | java | What does the code create ? | a new refactoring descriptor | public Move Descriptor ( String project , String description , String comment , Map arguments , int flags ) { super ( I Java Refactorings . MOVE , project , description , comment , arguments , flags ) ; f Move Policy = Java Refactoring Descriptor Util . get String ( f Arguments , ATTRIBUTE POLICY ) ; f Destination = Ja... | public MoveDescriptor ( String project , String description , String comment , Map arguments , int flags ) { super ( IJavaRefactorings . MOVE , project , description , comment , arguments , flags ) ; fMovePolicy = JavaRefactoringDescriptorUtil . getString ( fArguments , ATTRIBUTE_POLICY ) ; fDestination = JavaRefactori... | 468 |
java-test-9691 | java | What does the code do ? | the actual rendering of the included file | private boolean render Output ( Node node , Internal Context Adapter context , Writer writer ) throws IO Exception , Method Invocation Exception , Resource Not Found Exception { String arg = STRING ; if ( node == null ) { rsvc . error ( STRING ) ; return BOOL ; } Object value = node . value ( context ) ; if ( value == ... | private boolean renderOutput ( Node node , InternalContextAdapter context , Writer writer ) throws IOException , MethodInvocationException , ResourceNotFoundException { String arg = STRING ; if ( node == null ) { rsvc . error ( STRING ) ; return _BOOL ; } Object value = node . value ( context ) ; if ( value == null ) {... | 236 |
java-test-9692 | java | What is v mapped then ? | to category i | public static Discretization discretize ( double [ ] data , double [ ] cutoffs , String variable Name , List < String > categories ) { if ( cutoffs == null ) { throw new Null Pointer Exception ( ) ; } for ( int i = NUM ; i < cutoffs . length - NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + NUM ] ) ) { throw new... | public static Discretization discretize ( double [ ] _data , double [ ] cutoffs , String variableName , List < String > categories ) { if ( cutoffs == null ) { throw new NullPointerException ( ) ; } for ( int i = _NUM ; i < cutoffs . length - _NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + _NUM ] ) ) { throw ne... | 335 |
java-test-9693 | java | What will the discrete column returned use if cutoffs [ i - 1 ] < v < = cutoffs [ i ] ( where cutoffs [ - 1 ] = negative infinity ) , then v is mapped to category i . if cutoffs [ i - 1 ] < v < = cutoffs [ i ] ( where cutoffs [ - 1 ] = negative infinity ) , then v is mapped to category i . ? | these category names | public static Discretization discretize ( double [ ] data , double [ ] cutoffs , String variable Name , List < String > categories ) { if ( cutoffs == null ) { throw new Null Pointer Exception ( ) ; } for ( int i = NUM ; i < cutoffs . length - NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + NUM ] ) ) { throw new... | public static Discretization discretize ( double [ ] _data , double [ ] cutoffs , String variableName , List < String > categories ) { if ( cutoffs == null ) { throw new NullPointerException ( ) ; } for ( int i = _NUM ; i < cutoffs . length - _NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + _NUM ] ) ) { throw ne... | 335 |
java-test-9694 | java | What does the code discretiz using the specified cutoffs and category names ? | the continuous data in the given column | public static Discretization discretize ( double [ ] data , double [ ] cutoffs , String variable Name , List < String > categories ) { if ( cutoffs == null ) { throw new Null Pointer Exception ( ) ; } for ( int i = NUM ; i < cutoffs . length - NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + NUM ] ) ) { throw new... | public static Discretization discretize ( double [ ] _data , double [ ] cutoffs , String variableName , List < String > categories ) { if ( cutoffs == null ) { throw new NullPointerException ( ) ; } for ( int i = _NUM ; i < cutoffs . length - _NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + _NUM ] ) ) { throw ne... | 335 |
java-test-9695 | java | What will use these category names if cutoffs [ i - 1 ] < v < = cutoffs [ i ] ( where cutoffs [ - 1 ] = negative infinity ) , then v is mapped to category i . if cutoffs [ i - 1 ] < v < = cutoffs [ i ] ( where cutoffs [ - 1 ] = negative infinity ) , then v is mapped to category i . ? | the discrete column returned | public static Discretization discretize ( double [ ] data , double [ ] cutoffs , String variable Name , List < String > categories ) { if ( cutoffs == null ) { throw new Null Pointer Exception ( ) ; } for ( int i = NUM ; i < cutoffs . length - NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + NUM ] ) ) { throw new... | public static Discretization discretize ( double [ ] _data , double [ ] cutoffs , String variableName , List < String > categories ) { if ( cutoffs == null ) { throw new NullPointerException ( ) ; } for ( int i = _NUM ; i < cutoffs . length - _NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + _NUM ] ) ) { throw ne... | 335 |
java-test-9696 | java | How does the code discretiz the continuous data in the given column ? | using the specified cutoffs and category names | public static Discretization discretize ( double [ ] data , double [ ] cutoffs , String variable Name , List < String > categories ) { if ( cutoffs == null ) { throw new Null Pointer Exception ( ) ; } for ( int i = NUM ; i < cutoffs . length - NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + NUM ] ) ) { throw new... | public static Discretization discretize ( double [ ] _data , double [ ] cutoffs , String variableName , List < String > categories ) { if ( cutoffs == null ) { throw new NullPointerException ( ) ; } for ( int i = _NUM ; i < cutoffs . length - _NUM ; i ++ ) { if ( ! ( cutoffs [ i ] <= cutoffs [ i + _NUM ] ) ) { throw ne... | 335 |
java-test-9698 | java | What converts into a relational expression ? | a select statement ' s parse tree | public Rel Node convert Select ( Sql Select select , boolean top ) { final Sql Validator Scope select Scope = validator . get Where Scope ( select ) ; final Blackboard bb = create Blackboard ( select Scope , null , top ) ; convert Select Impl ( bb , select ) ; return bb . root ; } | public RelNode convertSelect ( SqlSelect select , boolean top ) { final SqlValidatorScope selectScope = validator . getWhereScope ( select ) ; final Blackboard bb = createBlackboard ( selectScope , null , top ) ; convertSelectImpl ( bb , select ) ; return bb . root ; } | 60 |
java-test-9701 | java | How will queries be send to server ? | according to max_allowed_packet size | public void execute Batch Multiple ( boolean must Execute On Master , Execution Result execution Result , final List < String > queries , int result Set Scroll Type ) throws Query Exception { cmd Prologue ( ) ; String first Sql = null ; int current Index = NUM ; int total Queries = queries . size ( ) ; Query Exception ... | public void executeBatchMultiple ( boolean mustExecuteOnMaster , ExecutionResult executionResult , final List < String > queries , int resultSetScrollType ) throws QueryException { cmdPrologue ( ) ; String firstSql = null ; int currentIndex = _NUM ; int totalQueries = queries . size ( ) ; QueryException exception = nul... | 316 |
java-test-9702 | java | When is this method used ? | when using text batch statement and using rewriting ( allowmultiqueries | | rewritebatchedstatements ) | public void execute Batch Multiple ( boolean must Execute On Master , Execution Result execution Result , final List < String > queries , int result Set Scroll Type ) throws Query Exception { cmd Prologue ( ) ; String first Sql = null ; int current Index = NUM ; int total Queries = queries . size ( ) ; Query Exception ... | public void executeBatchMultiple ( boolean mustExecuteOnMaster , ExecutionResult executionResult , final List < String > queries , int resultSetScrollType ) throws QueryException { cmdPrologue ( ) ; String firstSql = null ; int currentIndex = _NUM ; int totalQueries = queries . size ( ) ; QueryException exception = nul... | 316 |
java-test-9705 | java | How does the code compress them ? | using lzw compression | public static void compress ( ) { String input = Binary Std In . read String ( ) ; TST < Integer > st = new TST < Integer > ( ) ; for ( int i = NUM ; i < R ; i ++ ) st . put ( STRING + ( char ) i , i ) ; int code = R + NUM ; while ( input . length ( ) > NUM ) { String s = st . longest Prefix Of ( input ) ; Binary Std O... | public static void compress ( ) { String input = BinaryStdIn . readString ( ) ; TST < Integer > st = new TST < Integer > ( ) ; for ( int i = _NUM ; i < R ; i ++ ) st . put ( STRING + ( char ) i , i ) ; int code = R + _NUM ; while ( input . length ( ) > _NUM ) { String s = st . longestPrefixOf ( input ) ; BinaryStdOut .... | 179 |
java-test-9706 | java | What did a string truncate possibly ? | to fit into the maximum of 253 characters | public static final byte [ ] to Octets ( Attribute Type type , String str ) { final byte [ ] s = str . get Bytes ( Standard Charsets . UTF 8 ) ; byte [ ] octets ; if ( s . length > Attribute . MAX ATTRIBUTE VALUE LENGTH ) { octets = new byte [ Attribute . MAX ATTRIBUTE LENGTH ] ; octets [ NUM ] = ( byte ) type . get Ty... | public static final byte [ ] toOctets ( AttributeType type , String str ) { final byte [ ] s = str . getBytes ( StandardCharsets . UTF_8 ) ; byte [ ] octets ; if ( s . length > Attribute . MAX_ATTRIBUTE_VALUE_LENGTH ) { octets = new byte [ Attribute . MAX_ATTRIBUTE_LENGTH ] ; octets [ _NUM ] = ( byte ) type . getTypeCo... | 185 |
java-test-9707 | java | What can we do in between ? | other work | void calculate Counters ( ) { if ( ! is DB Available ( ) ) return ; long time = System . current Time Millis ( ) ; int total = NUM ; write . lock ( ) ; try { count Reset Feeds And Categories ( ) ; total += count Feeds With Unread ( ) ; count Categories With Unread ( ) ; count Special Categories ( total ) ; } finally { ... | void calculateCounters ( ) { if ( ! isDBAvailable ( ) ) return ; long time = System . currentTimeMillis ( ) ; int total = _NUM ; write . lock ( ) ; try { countResetFeedsAndCategories ( ) ; total += countFeedsWithUnread ( ) ; countCategoriesWithUnread ( ) ; countSpecialCategories ( total ) ; } finally { write . unlock (... | 111 |
java-test-9708 | java | What did the code set according to real amount of unread articles for feeds and categories ? | unread counters | void calculate Counters ( ) { if ( ! is DB Available ( ) ) return ; long time = System . current Time Millis ( ) ; int total = NUM ; write . lock ( ) ; try { count Reset Feeds And Categories ( ) ; total += count Feeds With Unread ( ) ; count Categories With Unread ( ) ; count Special Categories ( total ) ; } finally { ... | void calculateCounters ( ) { if ( ! isDBAvailable ( ) ) return ; long time = System . currentTimeMillis ( ) ; int total = _NUM ; write . lock ( ) ; try { countResetFeedsAndCategories ( ) ; total += countFeedsWithUnread ( ) ; countCategoriesWithUnread ( ) ; countSpecialCategories ( total ) ; } finally { write . unlock (... | 111 |
java-test-9709 | java | For what purpose do the tasks split in single transactions ? | so we can do other work in between | void calculate Counters ( ) { if ( ! is DB Available ( ) ) return ; long time = System . current Time Millis ( ) ; int total = NUM ; write . lock ( ) ; try { count Reset Feeds And Categories ( ) ; total += count Feeds With Unread ( ) ; count Categories With Unread ( ) ; count Special Categories ( total ) ; } finally { ... | void calculateCounters ( ) { if ( ! isDBAvailable ( ) ) return ; long time = System . currentTimeMillis ( ) ; int total = _NUM ; write . lock ( ) ; try { countResetFeedsAndCategories ( ) ; total += countFeedsWithUnread ( ) ; countCategoriesWithUnread ( ) ; countSpecialCategories ( total ) ; } finally { write . unlock (... | 111 |
java-test-9710 | java | For what purpose did the code set unread counters according to real amount of unread articles ? | for feeds and categories | void calculate Counters ( ) { if ( ! is DB Available ( ) ) return ; long time = System . current Time Millis ( ) ; int total = NUM ; write . lock ( ) ; try { count Reset Feeds And Categories ( ) ; total += count Feeds With Unread ( ) ; count Categories With Unread ( ) ; count Special Categories ( total ) ; } finally { ... | void calculateCounters ( ) { if ( ! isDBAvailable ( ) ) return ; long time = System . currentTimeMillis ( ) ; int total = _NUM ; write . lock ( ) ; try { countResetFeedsAndCategories ( ) ; total += countFeedsWithUnread ( ) ; countCategoriesWithUnread ( ) ; countSpecialCategories ( total ) ; } finally { write . unlock (... | 111 |
java-test-9711 | java | How do the tasks split so we can do other work in between ? | in single transactions | void calculate Counters ( ) { if ( ! is DB Available ( ) ) return ; long time = System . current Time Millis ( ) ; int total = NUM ; write . lock ( ) ; try { count Reset Feeds And Categories ( ) ; total += count Feeds With Unread ( ) ; count Categories With Unread ( ) ; count Special Categories ( total ) ; } finally { ... | void calculateCounters ( ) { if ( ! isDBAvailable ( ) ) return ; long time = System . currentTimeMillis ( ) ; int total = _NUM ; write . lock ( ) ; try { countResetFeedsAndCategories ( ) ; total += countFeedsWithUnread ( ) ; countCategoriesWithUnread ( ) ; countSpecialCategories ( total ) ; } finally { write . unlock (... | 111 |
java-test-9712 | java | When did user event call ? | before any change has been done | void event Pre Modify ( Action Type type , long position , boolean is Single ) { if ( type != current Action Type || ! is Single || System . current Time Millis ( ) - previous Time > MERGE TIME || ( type == Action Type . INSERT || type == Action Type . OVERWRITE ) && action Exclusive End ( ) != position || type == Acti... | void eventPreModify ( ActionType type , long position , boolean isSingle ) { if ( type != currentActionType || ! isSingle || System . currentTimeMillis ( ) - previousTime > MERGE_TIME || ( type == ActionType . INSERT || type == ActionType . OVERWRITE ) && actionExclusiveEnd ( ) != position || type == ActionType . DELET... | 147 |
java-test-9713 | java | What does the code do ? | a count on a given table | public int retrieve Row Count ( String table Name ) throws SQL Exception { Result Set rs = null ; int row Count = - NUM ; try { rs = statement . execute Query ( STRING + table Name ) ; rs . next ( ) ; row Count = rs . get Int ( NUM ) ; } finally { if ( rs != null ) { rs . close ( ) ; } } return row Count ; } | public int retrieveRowCount ( String tableName ) throws SQLException { ResultSet rs = null ; int rowCount = - _NUM ; try { rs = statement . executeQuery ( STRING + tableName ) ; rs . next ( ) ; rowCount = rs . getInt ( _NUM ) ; } finally { if ( rs != null ) { rs . close ( ) ; } } return rowCount ; } | 82 |
java-test-9715 | java | What does the code propose ? | a getter that is assumed to delegate to a method with the same name as the java method | private void propose Getter Delegate ( I Java Project project , I Method method , int invocation Offset , int indentation Units , boolean is Static , List < I Completion Proposal > proposals , int num Chars Filled , int num Chars To Overwrite ) throws Java Model Exception { String method Name = method . get Element Nam... | private void proposeGetterDelegate ( IJavaProject project , IMethod method , int invocationOffset , int indentationUnits , boolean isStatic , List < ICompletionProposal > proposals , int numCharsFilled , int numCharsToOverwrite ) throws JavaModelException { String methodName = method . getElementName ( ) ; String [ ] p... | 146 |
java-test-9716 | java | What does the code create ? | a new executor queue | public Executor create Queue ( int poolsize , String prefix ) { final Executor r = new Executor ( poolsize , prefix ) ; r . set Continue Existing Periodic Tasks After Shutdown Policy ( BOOL ) ; r . set Execute Existing Delayed Tasks After Shutdown Policy ( BOOL ) ; queues . add ( r ) ; return r ; } | public Executor createQueue ( int poolsize , String prefix ) { final Executor r = new Executor ( poolsize , prefix ) ; r . setContinueExistingPeriodicTasksAfterShutdownPolicy ( _BOOL ) ; r . setExecuteExistingDelayedTasksAfterShutdownPolicy ( _BOOL ) ; queues . add ( r ) ; return r ; } | 63 |
java-test-9717 | java | What does the code remove ? | the last elemtn of a path | private static String path Remove Last ( String path , Ref Boolean is Out Side ) { if ( path . length ( ) == NUM ) { is Out Side . set Value ( BOOL ) ; return STRING ; } else if ( path . ends With ( STRING ) ) { is Out Side . set Value ( BOOL ) ; return path . concat ( STRING ) ; } return path . substring ( NUM , path ... | private static String pathRemoveLast ( String path , RefBoolean isOutSide ) { if ( path . length ( ) == _NUM ) { isOutSide . setValue ( _BOOL ) ; return STRING ; } else if ( path . endsWith ( STRING ) ) { isOutSide . setValue ( _BOOL ) ; return path . concat ( STRING ) ; } return path . substring ( _NUM , path . lastIn... | 91 |
java-test-9718 | java | What does the code write to a file ? | the recorded dialogue | public void write To File ( String record File ) { log . fine ( STRING + record File ) ; try { XML Utils . write XML Document ( doc , record File ) ; } catch ( Runtime Exception e ) { log . warning ( STRING + record File ) ; } } | public void writeToFile ( String recordFile ) { log . fine ( STRING + recordFile ) ; try { XMLUtils . writeXMLDocument ( doc , recordFile ) ; } catch ( RuntimeException e ) { log . warning ( STRING + recordFile ) ; } } | 56 |
java-test-9719 | java | What did the code set without triggering an update of the decoder panel ? | a selection in the manufacturer list | void update Mfg List Without Trigger ( String mfg ) { m Mfg List . remove List Selection Listener ( m Mfg Listener ) ; m Mfg List . set Selected Value ( mfg , BOOL ) ; m Mfg List . add List Selection Listener ( m Mfg Listener ) ; } | void updateMfgListWithoutTrigger ( String mfg ) { mMfgList . removeListSelectionListener ( mMfgListener ) ; mMfgList . setSelectedValue ( mfg , _BOOL ) ; mMfgList . addListSelectionListener ( mMfgListener ) ; } | 53 |
java-test-9720 | java | How did the code set a selection in the manufacturer list ? | without triggering an update of the decoder panel | void update Mfg List Without Trigger ( String mfg ) { m Mfg List . remove List Selection Listener ( m Mfg Listener ) ; m Mfg List . set Selected Value ( mfg , BOOL ) ; m Mfg List . add List Selection Listener ( m Mfg Listener ) ; } | void updateMfgListWithoutTrigger ( String mfg ) { mMfgList . removeListSelectionListener ( mMfgListener ) ; mMfgList . setSelectedValue ( mfg , _BOOL ) ; mMfgList . addListSelectionListener ( mMfgListener ) ; } | 53 |
java-test-9721 | java | What do attributes assign it ? | a free column index | @ Override public int add Attribute ( Attribute a ) { if ( a == null ) { throw new Illegal Argument Exception ( STRING ) ; } else { int index = - NUM ; Attribute original = a ; a = ( Attribute ) a . clone ( ) ; if ( unused Column List . size ( ) > NUM ) { synchronized ( unused Column List ) { if ( unused Column List . ... | @ Override public int addAttribute ( Attribute a ) { if ( a == null ) { throw new IllegalArgumentException ( STRING ) ; } else { int index = - _NUM ; Attribute original = a ; a = ( Attribute ) a . clone ( ) ; if ( unusedColumnList . size ( ) > _NUM ) { synchronized ( unusedColumnList ) { if ( unusedColumnList . size ( ... | 167 |
java-test-9722 | java | What does the code write to the destination stream outstr ? | the full contents of instr | public static void pipe All ( Input Stream in Str , Output Stream out Str ) throws IO Exception { byte [ ] bs = new byte [ BUFFER SIZE ] ; int num Read ; while ( ( num Read = in Str . read ( bs , NUM , bs . length ) ) >= NUM ) { out Str . write ( bs , NUM , num Read ) ; } } | public static void pipeAll ( InputStream inStr , OutputStream outStr ) throws IOException { byte [ ] bs = new byte [ BUFFER_SIZE ] ; int numRead ; while ( ( numRead = inStr . read ( bs , _NUM , bs . length ) ) >= _NUM ) { outStr . write ( bs , _NUM , numRead ) ; } } | 75 |
java-test-9725 | java | For what purpose does the code escape the provided string ? | so that it no longer contains the constants . delimiter character | public static byte [ ] escape ( final byte [ ] bytes ) { final byte [ ] temp = new byte [ NUM * bytes . length ] ; int current Position = NUM ; for ( final byte b : bytes ) { if ( b == ESCAPE CHAR ) { temp [ current Position ++ ] = ESCAPE CHAR ; temp [ current Position ++ ] = REPLACEMENT CHAR ; } else if ( b == DELIMIT... | public static byte [ ] escape ( final byte [ ] bytes ) { final byte [ ] temp = new byte [ _NUM * bytes . length ] ; int currentPosition = _NUM ; for ( final byte b : bytes ) { if ( b == ESCAPE_CHAR ) { temp [ currentPosition ++ ] = ESCAPE_CHAR ; temp [ currentPosition ++ ] = REPLACEMENT_CHAR ; } else if ( b == DELIMITE... | 149 |
java-test-9726 | java | What does it contain no longer ? | the constants . delimiter character | public static byte [ ] escape ( final byte [ ] bytes ) { final byte [ ] temp = new byte [ NUM * bytes . length ] ; int current Position = NUM ; for ( final byte b : bytes ) { if ( b == ESCAPE CHAR ) { temp [ current Position ++ ] = ESCAPE CHAR ; temp [ current Position ++ ] = REPLACEMENT CHAR ; } else if ( b == DELIMIT... | public static byte [ ] escape ( final byte [ ] bytes ) { final byte [ ] temp = new byte [ _NUM * bytes . length ] ; int currentPosition = _NUM ; for ( final byte b : bytes ) { if ( b == ESCAPE_CHAR ) { temp [ currentPosition ++ ] = ESCAPE_CHAR ; temp [ currentPosition ++ ] = REPLACEMENT_CHAR ; } else if ( b == DELIMITE... | 149 |
java-test-9727 | java | What will it discover once a connection is established ? | all of the members | public Mongo Client client For Members ( Server Address ... seeds ) { List < Server Address > addresses = new Array List < > ( ) ; for ( Server Address seed Address : seeds ) { if ( seed Address != null ) addresses . add ( seed Address ) ; } return client For Members ( addresses ) ; } | public MongoClient clientForMembers ( ServerAddress ... seeds ) { List < ServerAddress > addresses = new ArrayList < > ( ) ; for ( ServerAddress seedAddress : seeds ) { if ( seedAddress != null ) addresses . add ( seedAddress ) ; } return clientForMembers ( addresses ) ; } | 63 |
java-test-9728 | java | What does the code obtain ? | a client connection to the replica set or cluster | public Mongo Client client For Members ( Server Address ... seeds ) { List < Server Address > addresses = new Array List < > ( ) ; for ( Server Address seed Address : seeds ) { if ( seed Address != null ) addresses . add ( seed Address ) ; } return client For Members ( addresses ) ; } | public MongoClient clientForMembers ( ServerAddress ... seeds ) { List < ServerAddress > addresses = new ArrayList < > ( ) ; for ( ServerAddress seedAddress : seeds ) { if ( seedAddress != null ) addresses . add ( seedAddress ) ; } return clientForMembers ( addresses ) ; } | 63 |
java-test-9729 | java | When will it discover all of the members ? | once a connection is established | public Mongo Client client For Members ( Server Address ... seeds ) { List < Server Address > addresses = new Array List < > ( ) ; for ( Server Address seed Address : seeds ) { if ( seed Address != null ) addresses . add ( seed Address ) ; } return client For Members ( addresses ) ; } | public MongoClient clientForMembers ( ServerAddress ... seeds ) { List < ServerAddress > addresses = new ArrayList < > ( ) ; for ( ServerAddress seedAddress : seeds ) { if ( seedAddress != null ) addresses . add ( seedAddress ) ; } return clientForMembers ( addresses ) ; } | 63 |
java-test-9730 | java | How does the code do the ? | readfully based on the input read | public static void read Fully ( Input Stream in , byte buf [ ] , int off , int len ) throws IO Exception { int to Read = len ; while ( to Read > NUM ) { int ret = in . read ( buf , off , to Read ) ; if ( ret < NUM ) { throw new IO Exception ( STRING ) ; } to Read -= ret ; off += ret ; } } | public static void readFully ( InputStream in , byte buf [ ] , int off , int len ) throws IOException { int toRead = len ; while ( toRead > _NUM ) { int ret = in . read ( buf , off , toRead ) ; if ( ret < _NUM ) { throw new IOException ( STRING ) ; } toRead -= ret ; off += ret ; } } | 81 |
java-test-9731 | java | By how much did the base on the input read ? | readfully | public static void read Fully ( Input Stream in , byte buf [ ] , int off , int len ) throws IO Exception { int to Read = len ; while ( to Read > NUM ) { int ret = in . read ( buf , off , to Read ) ; if ( ret < NUM ) { throw new IO Exception ( STRING ) ; } to Read -= ret ; off += ret ; } } | public static void readFully ( InputStream in , byte buf [ ] , int off , int len ) throws IOException { int toRead = len ; while ( toRead > _NUM ) { int ret = in . read ( buf , off , toRead ) ; if ( ret < _NUM ) { throw new IOException ( STRING ) ; } toRead -= ret ; off += ret ; } } | 81 |
java-test-9732 | java | How does the code find the top limit values ? | using given comparator | public static < X > void sort Top N ( X [ ] array , int offset , int limit , Comparator < ? super X > comp ) { partition Top N ( array , offset , limit , comp ) ; Arrays . sort ( array , offset , ( int ) Math . min ( ( long ) offset + limit , array . length ) , comp ) ; } | public static < X > void sortTopN ( X [ ] array , int offset , int limit , Comparator < ? super X > comp ) { partitionTopN ( array , offset , limit , comp ) ; Arrays . sort ( array , offset , ( int ) Math . min ( ( long ) offset + limit , array . length ) , comp ) ; } | 74 |
java-test-9733 | java | What does the code find using given comparator ? | the top limit values | public static < X > void sort Top N ( X [ ] array , int offset , int limit , Comparator < ? super X > comp ) { partition Top N ( array , offset , limit , comp ) ; Arrays . sort ( array , offset , ( int ) Math . min ( ( long ) offset + limit , array . length ) , comp ) ; } | public static < X > void sortTopN ( X [ ] array , int offset , int limit , Comparator < ? super X > comp ) { partitionTopN ( array , offset , limit , comp ) ; Arrays . sort ( array , offset , ( int ) Math . min ( ( long ) offset + limit , array . length ) , comp ) ; } | 74 |
java-test-9737 | java | When did the code update the request response average ? | in the last minute | public void record End Time ( ) { int ms Diff = ( int ) ( System . current Time Millis ( ) - current Request Start Time . get ( ) ) ; log . info ( STRING , ms Diff ) ; update Or Reset Req Rsp Avg Lst Hr ( update Or Reset Req Rsp Avg Lst Min ( ms Diff , BOOL ) , BOOL ) ; update Min Max Req Rsp Ms ( ms Diff ) ; if ( ms D... | public void recordEndTime ( ) { int msDiff = ( int ) ( System . currentTimeMillis ( ) - _currentRequestStartTime . get ( ) ) ; _log . info ( STRING , msDiff ) ; updateOrResetReqRspAvgLstHr ( updateOrResetReqRspAvgLstMin ( msDiff , _BOOL ) , _BOOL ) ; updateMinMaxReqRspMs ( msDiff ) ; if ( msDiff >= SUSPISCIOUS_RSP_TIME... | 121 |
java-test-9738 | java | What does the code compute ? | the response time of the request that just finished for the local thread | public void record End Time ( ) { int ms Diff = ( int ) ( System . current Time Millis ( ) - current Request Start Time . get ( ) ) ; log . info ( STRING , ms Diff ) ; update Or Reset Req Rsp Avg Lst Hr ( update Or Reset Req Rsp Avg Lst Min ( ms Diff , BOOL ) , BOOL ) ; update Min Max Req Rsp Ms ( ms Diff ) ; if ( ms D... | public void recordEndTime ( ) { int msDiff = ( int ) ( System . currentTimeMillis ( ) - _currentRequestStartTime . get ( ) ) ; _log . info ( STRING , msDiff ) ; updateOrResetReqRspAvgLstHr ( updateOrResetReqRspAvgLstMin ( msDiff , _BOOL ) , _BOOL ) ; updateMinMaxReqRspMs ( msDiff ) ; if ( msDiff >= SUSPISCIOUS_RSP_TIME... | 121 |
java-test-9739 | java | What did the code update in the last minute ? | the request response average | public void record End Time ( ) { int ms Diff = ( int ) ( System . current Time Millis ( ) - current Request Start Time . get ( ) ) ; log . info ( STRING , ms Diff ) ; update Or Reset Req Rsp Avg Lst Hr ( update Or Reset Req Rsp Avg Lst Min ( ms Diff , BOOL ) , BOOL ) ; update Min Max Req Rsp Ms ( ms Diff ) ; if ( ms D... | public void recordEndTime ( ) { int msDiff = ( int ) ( System . currentTimeMillis ( ) - _currentRequestStartTime . get ( ) ) ; _log . info ( STRING , msDiff ) ; updateOrResetReqRspAvgLstHr ( updateOrResetReqRspAvgLstMin ( msDiff , _BOOL ) , _BOOL ) ; updateMinMaxReqRspMs ( msDiff ) ; if ( msDiff >= SUSPISCIOUS_RSP_TIME... | 121 |
java-test-9740 | java | What does the code update ? | the actions that depend on the state of a single project | private void update Actions ( final I Navi Project project ) { m load Project Action . set Enabled ( ! project . is Loaded ( ) ) ; if ( m add Address Space Action != null ) { m add Address Space Action . set Enabled ( project . is Loaded ( ) ) ; } m search View Action . set Enabled ( project . is Loaded ( ) ) ; m forwa... | private void updateActions ( final INaviProject project ) { m_loadProjectAction . setEnabled ( ! project . isLoaded ( ) ) ; if ( m_addAddressSpaceAction != null ) { m_addAddressSpaceAction . setEnabled ( project . isLoaded ( ) ) ; } m_searchViewAction . setEnabled ( project . isLoaded ( ) ) ; m_forwardAction . setEnabl... | 90 |
java-test-9741 | java | What does a method create ? | the workflow method for removing vplex volumes from a consistency group | protected Workflow . Method create Remove Volumes From CG Method ( URI vplex URI , URI cg URI , List < URI > vplex Volume UR Is ) { return new Workflow . Method ( REMOVE VOLUMES FROM CG STEP , vplex URI , cg URI , vplex Volume UR Is ) ; } | protected Workflow . Method createRemoveVolumesFromCGMethod ( URI vplexURI , URI cgURI , List < URI > vplexVolumeURIs ) { return new Workflow . Method ( REMOVE_VOLUMES_FROM_CG_STEP , vplexURI , cgURI , vplexVolumeURIs ) ; } | 54 |
java-test-9742 | java | What do setconfig messages want ? | to change the number of containers of a job | private void handle Yarn Container Change ( String container Count As String ) throws IO Exception , Yarn Exception { String application Id = yarn Util . get Running App Id ( job Name , job ID ) ; int container Count = Integer . value Of ( container Count As String ) ; int current Num Task = get Current Num Tasks ( ) ;... | private void handleYarnContainerChange ( String containerCountAsString ) throws IOException , YarnException { String applicationId = yarnUtil . getRunningAppId ( jobName , jobID ) ; int containerCount = Integer . valueOf ( containerCountAsString ) ; int currentNumTask = getCurrentNumTasks ( ) ; int currentNumContainers... | 312 |
java-test-9743 | java | What do that change ? | the number of containers of a job | private void handle Yarn Container Change ( String container Count As String ) throws IO Exception , Yarn Exception { String application Id = yarn Util . get Running App Id ( job Name , job ID ) ; int container Count = Integer . value Of ( container Count As String ) ; int current Num Task = get Current Num Tasks ( ) ;... | private void handleYarnContainerChange ( String containerCountAsString ) throws IOException , YarnException { String applicationId = yarnUtil . getRunningAppId ( jobName , jobID ) ; int containerCount = Integer . valueOf ( containerCountAsString ) ; int currentNumTask = getCurrentNumTasks ( ) ; int currentNumContainers... | 312 |
java-test-9744 | java | What does this method handle ? | setconfig messages that want to change the number of containers of a job | private void handle Yarn Container Change ( String container Count As String ) throws IO Exception , Yarn Exception { String application Id = yarn Util . get Running App Id ( job Name , job ID ) ; int container Count = Integer . value Of ( container Count As String ) ; int current Num Task = get Current Num Tasks ( ) ;... | private void handleYarnContainerChange ( String containerCountAsString ) throws IOException , YarnException { String applicationId = yarnUtil . getRunningAppId ( jobName , jobID ) ; int containerCount = Integer . valueOf ( containerCountAsString ) ; int currentNumTask = getCurrentNumTasks ( ) ; int currentNumContainers... | 312 |
java-test-9745 | java | What does the code add ? | the contents from the specified results | public void add Results ( Add On Changes Result result ) { selected Add Ons . add All ( result . get Selected Add Ons ( ) ) ; old Versions . add All ( result . old Versions ) ; uninstalls . add All ( result . get Uninstalls ( ) ) ; new Versions . add All ( result . get New Versions ( ) ) ; installs . add All ( result .... | public void addResults ( AddOnChangesResult result ) { selectedAddOns . addAll ( result . getSelectedAddOns ( ) ) ; oldVersions . addAll ( result . oldVersions ) ; uninstalls . addAll ( result . getUninstalls ( ) ) ; newVersions . addAll ( result . getNewVersions ( ) ) ; installs . addAll ( result . getInstalls ( ) ) ;... | 132 |
java-test-9747 | java | Where does a tag of the correct version exist ? | in this file | public boolean seek ( Byte Buffer byte Buffer ) { byte Buffer . rewind ( ) ; logger . config ( STRING + byte Buffer . position ( ) + STRING + byte Buffer . limit ( ) + STRING + byte Buffer . capacity ( ) ) ; byte [ ] tag Identifier = new byte [ FIELD TAGID LENGTH ] ; byte Buffer . get ( tag Identifier , NUM , FIELD TAG... | public boolean seek ( ByteBuffer byteBuffer ) { byteBuffer . rewind ( ) ; logger . config ( STRING + byteBuffer . position ( ) + STRING + byteBuffer . limit ( ) + STRING + byteBuffer . capacity ( ) ) ; byte [ ] tagIdentifier = new byte [ FIELD_TAGID_LENGTH ] ; byteBuffer . get ( tagIdentifier , _NUM , FIELD_TAGID_LENGT... | 133 |
java-test-9748 | java | What exist in this file ? | a tag of the correct version | public boolean seek ( Byte Buffer byte Buffer ) { byte Buffer . rewind ( ) ; logger . config ( STRING + byte Buffer . position ( ) + STRING + byte Buffer . limit ( ) + STRING + byte Buffer . capacity ( ) ) ; byte [ ] tag Identifier = new byte [ FIELD TAGID LENGTH ] ; byte Buffer . get ( tag Identifier , NUM , FIELD TAG... | public boolean seek ( ByteBuffer byteBuffer ) { byteBuffer . rewind ( ) ; logger . config ( STRING + byteBuffer . position ( ) + STRING + byteBuffer . limit ( ) + STRING + byteBuffer . capacity ( ) ) ; byte [ ] tagIdentifier = new byte [ FIELD_TAGID_LENGTH ] ; byteBuffer . get ( tagIdentifier , _NUM , FIELD_TAGID_LENGT... | 133 |
java-test-9749 | java | What does the code write creating the directory if it doesn ' t exist ? | the bitmap the directory | @ Nullable @ Worker Thread static File write Bitmap To Directory ( @ Non Null Bitmap bitmap , @ Non Null File directory ) { if ( ! directory . mkdirs ( ) && ! directory . exists ( ) ) { Log . e ( TAG , STRING ) ; return null ; } return write Bitmap To File ( bitmap , new File ( directory , create Unique Filename ( BITM... | @ Nullable @ WorkerThread static File writeBitmapToDirectory ( @ NonNull Bitmap bitmap , @ NonNull File directory ) { if ( ! directory . mkdirs ( ) && ! directory . exists ( ) ) { Log . e ( TAG , STRING ) ; return null ; } return writeBitmapToFile ( bitmap , new File ( directory , createUniqueFilename ( BITMAP_PREFIX )... | 79 |
java-test-9750 | java | What does the code merge with the given merge base ? | the notes from local and origin commits | private void merge Notes And Push ( Rev Walk rev Walk , String ref Name , Rev Commit base Commit , Rev Commit local Commit , Rev Commit origin Commit ) throws Git Client Exception { int remaining Lock Failure Calls = Jgit Utils . MAX LOCK FAILURE CALLS ; while ( BOOL ) { try { Note Map their Note Map = Note Map . read ... | private void mergeNotesAndPush ( RevWalk revWalk , String refName , RevCommit baseCommit , RevCommit localCommit , RevCommit originCommit ) throws GitClientException { int remainingLockFailureCalls = JgitUtils . MAX_LOCK_FAILURE_CALLS ; while ( _BOOL ) { try { NoteMap theirNoteMap = NoteMap . read ( revWalk . getObject... | 428 |
java-test-9757 | java | What does the code generate ? | the final mosaic image | public Mosaic Jpeg generate Final Mosaic ( boolean high Res ) { int mosaic Return Code = m Mosaic Frame Processor . create Mosaic ( high Res ) ; if ( mosaic Return Code == Mosaic . MOSAIC RET CANCELLED ) { return null ; } else if ( mosaic Return Code == Mosaic . MOSAIC RET ERROR ) { return new Mosaic Jpeg ( ) ; } byte ... | public MosaicJpeg generateFinalMosaic ( boolean highRes ) { int mosaicReturnCode = mMosaicFrameProcessor . createMosaic ( highRes ) ; if ( mosaicReturnCode == Mosaic . MOSAIC_RET_CANCELLED ) { return null ; } else if ( mosaicReturnCode == Mosaic . MOSAIC_RET_ERROR ) { return new MosaicJpeg ( ) ; } byte [ ] imageData = ... | 415 |
java-test-9759 | java | What does this method upload to the remote server ? | a content | public void upload ( String file Name , Input Stream input Stream , long restart At , long stream Offset , FTP Data Transfer Listener listener ) throws Illegal State Exception , IO Exception , FTP Illegal Reply Exception , FTP Exception , FTP Data Transfer Exception , FTP Aborted Exception { synchronized ( lock ) { if ... | public void upload ( String fileName , InputStream inputStream , long restartAt , long streamOffset , FTPDataTransferListener listener ) throws IllegalStateException , IOException , FTPIllegalReplyException , FTPException , FTPDataTransferException , FTPAbortedException { synchronized ( lock ) { if ( ! connected ) { th... | 927 |
java-test-9760 | java | What may this method can be used ? | to test if a field is present | @ Override public boolean is Set ( Datatype Constants . Field field ) { if ( field == null ) { String method Name = STRING + STRING ; throw new Null Pointer Exception ( Datatype Message Formatter . format Message ( null , STRING , new Object [ ] { method Name } ) ) ; } if ( field == Datatype Constants . YEARS ) { retur... | @ Override public boolean isSet ( DatatypeConstants . Field field ) { if ( field == null ) { String methodName = STRING + STRING ; throw new NullPointerException ( DatatypeMessageFormatter . formatMessage ( null , STRING , new Object [ ] { methodName } ) ) ; } if ( field == DatatypeConstants . YEARS ) { return years !=... | 198 |
java-test-9761 | java | What is passed on the way to the far side of the search space ? | the best subset | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9762 | java | What does the code produce ? | a ranked list of attributes | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9763 | java | What reflect individual merit values ? | the merit associated with adding the corresponding attribute to the subset | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9764 | java | For what purpose is by this function called search ? | to complete the traversal of the the search space | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9765 | java | Where is the best subset passed ? | on the way to the far side of the search space | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9766 | java | When are they added to the subset ? | during a forward selection search | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9767 | java | When must search have been performed ? | prior to calling this function . search | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9768 | java | What did the merit associated with adding the corresponding attribute to the subset reflect ? | individual merit values | @ Override public double [ ] [ ] ranked Attributes ( ) throws Exception { if ( m ranked Atts == null || m ranked So Far == - NUM ) { throw new Exception ( STRING + STRING ) ; } m do Rank = BOOL ; search ( m AS Eval , null ) ; double [ ] [ ] final rank = new double [ m ranked So Far ] [ NUM ] ; for ( int i = NUM ; i < m... | @ Override public double [ ] [ ] rankedAttributes ( ) throws Exception { if ( m_rankedAtts == null || m_rankedSoFar == - _NUM ) { throw new Exception ( STRING + STRING ) ; } m_doRank = _BOOL ; search ( m_ASEval , null ) ; double [ ] [ ] final_rank = new double [ m_rankedSoFar ] [ _NUM ] ; for ( int i = _NUM ; i < m_ran... | 220 |
java-test-9769 | java | What do documentation source table list ? | global acis | @ Override public void execute ( ) throws Mojo Execution Exception , Mojo Failure Exception { try { read Acis ( get Aci Descriptions ( ) ) ; } catch ( IO Exception e ) { throw new Mojo Failure Exception ( e . get Message ( ) , e ) ; } File table = new File ( output Directory , STRING ) ; try { write String To File ( ge... | @ Override public void execute ( ) throws MojoExecutionException , MojoFailureException { try { readAcis ( getAciDescriptions ( ) ) ; } catch ( IOException e ) { throw new MojoFailureException ( e . getMessage ( ) , e ) ; } File table = new File ( outputDirectory , STRING ) ; try { writeStringToFile ( getGlobalAcisTabl... | 108 |
java-test-9770 | java | What is listing global acis ? | documentation source table | @ Override public void execute ( ) throws Mojo Execution Exception , Mojo Failure Exception { try { read Acis ( get Aci Descriptions ( ) ) ; } catch ( IO Exception e ) { throw new Mojo Failure Exception ( e . get Message ( ) , e ) ; } File table = new File ( output Directory , STRING ) ; try { write String To File ( ge... | @ Override public void execute ( ) throws MojoExecutionException , MojoFailureException { try { readAcis ( getAciDescriptions ( ) ) ; } catch ( IOException e ) { throw new MojoFailureException ( e . getMessage ( ) , e ) ; } File table = new File ( outputDirectory , STRING ) ; try { writeStringToFile ( getGlobalAcisTabl... | 108 |
java-test-9771 | java | What do a new attribute name use ? | the given string name | public Name ( String name ) { if ( name == null ) { throw new Null Pointer Exception ( STRING ) ; } if ( ! is Valid ( name ) ) { throw new Illegal Argument Exception ( name ) ; } this . name = name . intern ( ) ; } | public Name ( String name ) { if ( name == null ) { throw new NullPointerException ( STRING ) ; } if ( ! isValid ( name ) ) { throw new IllegalArgumentException ( name ) ; } this . name = name . intern ( ) ; } | 55 |
java-test-9772 | java | What is using the given string name ? | a new attribute name | public Name ( String name ) { if ( name == null ) { throw new Null Pointer Exception ( STRING ) ; } if ( ! is Valid ( name ) ) { throw new Illegal Argument Exception ( name ) ; } this . name = name . intern ( ) ; } | public Name ( String name ) { if ( name == null ) { throw new NullPointerException ( STRING ) ; } if ( ! isValid ( name ) ) { throw new IllegalArgumentException ( name ) ; } this . name = name . intern ( ) ; } | 55 |
java-test-9773 | java | How does a new attribute name construct ? | using the given string name | public Name ( String name ) { if ( name == null ) { throw new Null Pointer Exception ( STRING ) ; } if ( ! is Valid ( name ) ) { throw new Illegal Argument Exception ( name ) ; } this . name = name . intern ( ) ; } | public Name ( String name ) { if ( name == null ) { throw new NullPointerException ( STRING ) ; } if ( ! isValid ( name ) ) { throw new IllegalArgumentException ( name ) ; } this . name = name . intern ( ) ; } | 55 |
java-test-9774 | java | What does the code validate ? | the vmrr script | public synchronized void initialize ( ) throws Replicator Exception { File control Script = new File ( vmrr Control Script ) ; if ( control Script . is File ( ) && control Script . can Execute ( ) ) { logger . info ( STRING + control Script . get Absolute Path ( ) ) ; } else { throw new Replicator Exception ( STRING + ... | public synchronized void initialize ( ) throws ReplicatorException { File controlScript = new File ( vmrrControlScript ) ; if ( controlScript . isFile ( ) && controlScript . canExecute ( ) ) { logger . info ( STRING + controlScript . getAbsolutePath ( ) ) ; } else { throw new ReplicatorException ( STRING + controlScrip... | 79 |
java-test-9775 | java | When must this be called ? | before making other management api calls | public synchronized void initialize ( ) throws Replicator Exception { File control Script = new File ( vmrr Control Script ) ; if ( control Script . is File ( ) && control Script . can Execute ( ) ) { logger . info ( STRING + control Script . get Absolute Path ( ) ) ; } else { throw new Replicator Exception ( STRING + ... | public synchronized void initialize ( ) throws ReplicatorException { File controlScript = new File ( vmrrControlScript ) ; if ( controlScript . isFile ( ) && controlScript . canExecute ( ) ) { logger . info ( STRING + controlScript . getAbsolutePath ( ) ) ; } else { throw new ReplicatorException ( STRING + controlScrip... | 79 |
java-test-9776 | java | Why does it pass consistently ? | because of some internal error of jruby | @ Ignore @ Test public void test From Folder ( ) throws Exception { final File test Folder = new File ( url . get File ( ) , STRING ) ; final File expected Folder = new File ( url . get File ( ) , STRING ) ; Wro Test Utils . compare From Different Folders By Name ( test Folder , expected Folder , STRING , STRING , proc... | @ Ignore @ Test public void testFromFolder ( ) throws Exception { final File testFolder = new File ( url . getFile ( ) , STRING ) ; final File expectedFolder = new File ( url . getFile ( ) , STRING ) ; WroTestUtils . compareFromDifferentFoldersByName ( testFolder , expectedFolder , STRING , STRING , processor ) ; } | 75 |
java-test-9777 | java | What can i not find ? | a maven directive to make module rnu tests from their module dir | @ Ignore @ Test public void test From Folder ( ) throws Exception { final File test Folder = new File ( url . get File ( ) , STRING ) ; final File expected Folder = new File ( url . get File ( ) , STRING ) ; Wro Test Utils . compare From Different Folders By Name ( test Folder , expected Folder , STRING , STRING , proc... | @ Ignore @ Test public void testFromFolder ( ) throws Exception { final File testFolder = new File ( url . getFile ( ) , STRING ) ; final File expectedFolder = new File ( url . getFile ( ) , STRING ) ; WroTestUtils . compareFromDifferentFoldersByName ( testFolder , expectedFolder , STRING , STRING , processor ) ; } | 75 |
java-test-9778 | java | Why is this test ignore ? | since it doesn ' t pass consistently because of some internal error of jruby | @ Ignore @ Test public void test From Folder ( ) throws Exception { final File test Folder = new File ( url . get File ( ) , STRING ) ; final File expected Folder = new File ( url . get File ( ) , STRING ) ; Wro Test Utils . compare From Different Folders By Name ( test Folder , expected Folder , STRING , STRING , proc... | @ Ignore @ Test public void testFromFolder ( ) throws Exception { final File testFolder = new File ( url . getFile ( ) , STRING ) ; final File expectedFolder = new File ( url . getFile ( ) , STRING ) ; WroTestUtils . compareFromDifferentFoldersByName ( testFolder , expectedFolder , STRING , STRING , processor ) ; } | 75 |
java-test-9779 | java | What do the error be ? | that the paths used by the sass import directive are based on the current working dir . this test will pass when run from the wro4j - extensions module , but error if run from the parent ( wro4j ) project . it ' s impossible to change the current working dir from within a running jvm , and i can not find a maven direct... | @ Ignore @ Test public void test From Folder ( ) throws Exception { final File test Folder = new File ( url . get File ( ) , STRING ) ; final File expected Folder = new File ( url . get File ( ) , STRING ) ; Wro Test Utils . compare From Different Folders By Name ( test Folder , expected Folder , STRING , STRING , proc... | @ Ignore @ Test public void testFromFolder ( ) throws Exception { final File testFolder = new File ( url . getFile ( ) , STRING ) ; final File expectedFolder = new File ( url . getFile ( ) , STRING ) ; WroTestUtils . compareFromDifferentFoldersByName ( testFolder , expectedFolder , STRING , STRING , processor ) ; } | 75 |
java-test-9780 | java | When will this test pass ? | when run from the wro4j - extensions module | @ Ignore @ Test public void test From Folder ( ) throws Exception { final File test Folder = new File ( url . get File ( ) , STRING ) ; final File expected Folder = new File ( url . get File ( ) , STRING ) ; Wro Test Utils . compare From Different Folders By Name ( test Folder , expected Folder , STRING , STRING , proc... | @ Ignore @ Test public void testFromFolder ( ) throws Exception { final File testFolder = new File ( url . getFile ( ) , STRING ) ; final File expectedFolder = new File ( url . getFile ( ) , STRING ) ; WroTestUtils . compareFromDifferentFoldersByName ( testFolder , expectedFolder , STRING , STRING , processor ) ; } | 75 |
java-test-9781 | java | What has means what ? | the received command | public boolean sort ( String in Package ) { if ( is Address Set ) { try { switch ( in Package . char At ( NUM ) ) { case STRING : set Speed ( Integer . parse Int ( in Package . substring ( NUM ) ) ) ; break ; case STRING : e Stop ( ) ; break ; case STRING : handle Function ( in Package ) ; break ; case STRING : force F... | public boolean sort ( String inPackage ) { if ( isAddressSet ) { try { switch ( inPackage . charAt ( _NUM ) ) { case STRING : setSpeed ( Integer . parseInt ( inPackage . substring ( _NUM ) ) ) ; break ; case STRING : eStop ( ) ; break ; case STRING : handleFunction ( inPackage ) ; break ; case STRING : forceFunction ( ... | 546 |
java-test-9782 | java | What do a rest listener recieve ? | notifications on policy changes | boolean add REST Remote Policy Listener ( SSO Token app Token , String service Name , String notification URL , boolean re Register ) { boolean status = BOOL ; if ( debug . message Enabled ( ) ) { debug . message ( STRING + STRING + service Name + STRING + notification URL ) ; } if ( remote Policy Listeners . contains ... | boolean addRESTRemotePolicyListener ( SSOToken appToken , String serviceName , String notificationURL , boolean reRegister ) { boolean status = _BOOL ; if ( debug . messageEnabled ( ) ) { debug . message ( STRING + STRING + serviceName + STRING + notificationURL ) ; } if ( remotePolicyListeners . contains ( serviceName... | 403 |
java-test-9783 | java | What recieves notifications on policy changes ? | a rest listener | boolean add REST Remote Policy Listener ( SSO Token app Token , String service Name , String notification URL , boolean re Register ) { boolean status = BOOL ; if ( debug . message Enabled ( ) ) { debug . message ( STRING + STRING + service Name + STRING + notification URL ) ; } if ( remote Policy Listeners . contains ... | boolean addRESTRemotePolicyListener ( SSOToken appToken , String serviceName , String notificationURL , boolean reRegister ) { boolean status = _BOOL ; if ( debug . messageEnabled ( ) ) { debug . message ( STRING + STRING + serviceName + STRING + notificationURL ) ; } if ( remotePolicyListeners . contains ( serviceName... | 403 |
java-test-9784 | java | What does a strict check perform ? | full input validation | private static boolean is Ip Address ( String name ) { if ( IP Address Util . is I Pv 4 Literal Address ( name ) || IP Address Util . is I Pv 6 Literal Address ( name ) ) { return BOOL ; } else { return BOOL ; } } | private static boolean isIpAddress ( String name ) { if ( IPAddressUtil . isIPv4LiteralAddress ( name ) || IPAddressUtil . isIPv6LiteralAddress ( name ) ) { return _BOOL ; } else { return _BOOL ; } } | 53 |
java-test-9785 | java | What does not need to be a fully qualified name ? | the hostname | private static boolean is Ip Address ( String name ) { if ( IP Address Util . is I Pv 4 Literal Address ( name ) || IP Address Util . is I Pv 6 Literal Address ( name ) ) { return BOOL ; } else { return BOOL ; } } | private static boolean isIpAddress ( String name ) { if ( IPAddressUtil . isIPv4LiteralAddress ( name ) || IPAddressUtil . isIPv6LiteralAddress ( name ) ) { return _BOOL ; } else { return _BOOL ; } } | 53 |
java-test-9786 | java | What performs full input validation ? | a strict check | private static boolean is Ip Address ( String name ) { if ( IP Address Util . is I Pv 4 Literal Address ( name ) || IP Address Util . is I Pv 6 Literal Address ( name ) ) { return BOOL ; } else { return BOOL ; } } | private static boolean isIpAddress ( String name ) { if ( IPAddressUtil . isIPv4LiteralAddress ( name ) || IPAddressUtil . isIPv6LiteralAddress ( name ) ) { return _BOOL ; } else { return _BOOL ; } } | 53 |
java-test-9787 | java | What does the hostname not need ? | to be a fully qualified name | private static boolean is Ip Address ( String name ) { if ( IP Address Util . is I Pv 4 Literal Address ( name ) || IP Address Util . is I Pv 6 Literal Address ( name ) ) { return BOOL ; } else { return BOOL ; } } | private static boolean isIpAddress ( String name ) { if ( IPAddressUtil . isIPv4LiteralAddress ( name ) || IPAddressUtil . isIPv6LiteralAddress ( name ) ) { return _BOOL ; } else { return _BOOL ; } } | 53 |
java-test-9788 | java | What does the code save to a stream ? | the state of this map | private void write Object ( java . io . Object Output Stream s ) throws java . io . IO Exception { s . default Write Object ( ) ; for ( Node < K , V > n = find First ( ) ; n != null ; n = n . next ) { V v = n . get Valid Value ( ) ; if ( v != null ) { s . write Object ( n . key ) ; s . write Object ( v ) ; } } s . writ... | private void writeObject ( java . io . ObjectOutputStream s ) throws java . io . IOException { s . defaultWriteObject ( ) ; for ( Node < K , V > n = findFirst ( ) ; n != null ; n = n . next ) { V v = n . getValidValue ( ) ; if ( v != null ) { s . writeObject ( n . key ) ; s . writeObject ( v ) ; } } s . writeObject ( n... | 103 |
java-test-9789 | java | What does the code add ? | all child comments | private void add Child Comments ( List < ? extends I Endless Adaptable > loaded Items , Comment comment , List < I Endless Adaptable > displayed Comments ) { for ( int j = loaded Items . index Of ( comment ) + NUM ; j < loaded Items . size ( ) ; ++ j ) { Comment child = ( Comment ) loaded Items . get ( j ) ; if ( child... | private void addChildComments ( List < ? extends IEndlessAdaptable > loadedItems , Comment comment , List < IEndlessAdaptable > displayedComments ) { for ( int j = loadedItems . indexOf ( comment ) + _NUM ; j < loadedItems . size ( ) ; ++ j ) { Comment child = ( Comment ) loadedItems . get ( j ) ; if ( child . getDepth... | 101 |
java-test-9790 | java | How did close segment states open previously ? | with opensegmentstates | private Apply Deletes Result close Segment States ( Index Writer . Reader Pool pool , Segment State [ ] seg States , boolean success , long gen ) throws IO Exception { int num Readers = seg States . length ; Throwable first Exc = null ; List < Segment Commit Info > all Deleted = null ; long tot Del Count = NUM ; for ( ... | private ApplyDeletesResult closeSegmentStates ( IndexWriter . ReaderPool pool , SegmentState [ ] segStates , boolean success , long gen ) throws IOException { int numReaders = segStates . length ; Throwable firstExc = null ; List < SegmentCommitInfo > allDeleted = null ; long totDelCount = _NUM ; for ( int j = _NUM ; j... | 348 |
java-test-9791 | java | What does the code compute ? | the similarity between two signature , which is also an estimation of the cosine similarity between the two vectors | public final double similarity ( final boolean [ ] sig 1 , final boolean [ ] sig 2 ) { double agg = NUM ; for ( int i = NUM ; i < sig 1 . length ; i ++ ) { if ( sig 1 [ i ] == sig 2 [ i ] ) { agg ++ ; } } agg = agg / sig 1 . length ; return Math . cos ( ( NUM - agg ) * Math . PI ) ; } | public final double similarity ( final boolean [ ] sig1 , final boolean [ ] sig2 ) { double agg = _NUM ; for ( int i = _NUM ; i < sig1 . length ; i ++ ) { if ( sig1 [ i ] == sig2 [ i ] ) { agg ++ ; } } agg = agg / sig1 . length ; return Math . cos ( ( _NUM - agg ) * Math . PI ) ; } | 89 |
java-test-9792 | java | What do a midlet overwrite ? | the supplied jad file | public static void sign ( File jad File , File jar File , RSA Private Key private Key , X509 Certificate [ ] certificate Chain , int certificate Number ) throws IO Exception , Crypto Exception { File tmp File = File . create Temp File ( STRING , STRING ) ; tmp File . delete On Exit ( ) ; sign ( jad File , tmp File , ja... | public static void sign ( File jadFile , File jarFile , RSAPrivateKey privateKey , X509Certificate [ ] certificateChain , int certificateNumber ) throws IOException , CryptoException { File tmpFile = File . createTempFile ( STRING , STRING ) ; tmpFile . deleteOnExit ( ) ; sign ( jadFile , tmpFile , jarFile , privateKey... | 115 |
java-test-9793 | java | What is overwriting the supplied jad file ? | a midlet | public static void sign ( File jad File , File jar File , RSA Private Key private Key , X509 Certificate [ ] certificate Chain , int certificate Number ) throws IO Exception , Crypto Exception { File tmp File = File . create Temp File ( STRING , STRING ) ; tmp File . delete On Exit ( ) ; sign ( jad File , tmp File , ja... | public static void sign ( File jadFile , File jarFile , RSAPrivateKey privateKey , X509Certificate [ ] certificateChain , int certificateNumber ) throws IOException , CryptoException { File tmpFile = File . createTempFile ( STRING , STRING ) ; tmpFile . deleteOnExit ( ) ; sign ( jadFile , tmpFile , jarFile , privateKey... | 115 |
java-test-9794 | java | What does the code validate ? | the new password fields | private boolean validate New Password ( Request And Response request And Response , final User edited User , final boolean current Is Edited User , final String new Password , final String new Password 2 ) throws IO Exception { boolean has Errors = BOOL ; if ( new Password == null || new Password . is Empty ( ) ) { add... | private boolean validateNewPassword ( RequestAndResponse requestAndResponse , final User editedUser , final boolean currentIsEditedUser , final String newPassword , final String newPassword2 ) throws IOException { boolean hasErrors = _BOOL ; if ( newPassword == null || newPassword . isEmpty ( ) ) { addErrorMessage ( re... | 265 |
java-test-9795 | java | What does the code get based on where the mouse is , distance and azimuth angle as the mouse moves ? | the line and circle ready for the map repaint | public void mouse Moved ( Mouse Event e ) { mouse Support . fire Map Mouse Moved ( e ) ; if ( e . get Source ( ) instanceof Map Bean ) { if ( draw Distance Objects && the Map != null ) { double lat 1 , lat 2 , long 1 , long 2 ; r Point 2 = the Map . get Coordinates ( e ) ; the Map . repaint ( ) ; if ( info Delegator !=... | public void mouseMoved ( MouseEvent e ) { mouseSupport . fireMapMouseMoved ( e ) ; if ( e . getSource ( ) instanceof MapBean ) { if ( drawDistanceObjects && theMap != null ) { double lat1 , lat2 , long1 , long2 ; rPoint2 = theMap . getCoordinates ( e ) ; theMap . repaint ( ) ; if ( infoDelegator != null ) { Debug . mes... | 292 |
java-test-9796 | java | When does the code get the line and circle ready for the map repaint based on where the mouse is , distance and azimuth angle ? | as the mouse moves | public void mouse Moved ( Mouse Event e ) { mouse Support . fire Map Mouse Moved ( e ) ; if ( e . get Source ( ) instanceof Map Bean ) { if ( draw Distance Objects && the Map != null ) { double lat 1 , lat 2 , long 1 , long 2 ; r Point 2 = the Map . get Coordinates ( e ) ; the Map . repaint ( ) ; if ( info Delegator !=... | public void mouseMoved ( MouseEvent e ) { mouseSupport . fireMapMouseMoved ( e ) ; if ( e . getSource ( ) instanceof MapBean ) { if ( drawDistanceObjects && theMap != null ) { double lat1 , lat2 , long1 , long2 ; rPoint2 = theMap . getCoordinates ( e ) ; theMap . repaint ( ) ; if ( infoDelegator != null ) { Debug . mes... | 292 |
java-test-9797 | java | What be used within the closure ? | this input stream | public static < T , U extends Input Stream > T with Stream ( U stream , @ Closure Params ( value = First Param . class ) Closure < T > closure ) throws IO Exception { try { T result = closure . call ( stream ) ; Input Stream temp = stream ; stream = null ; temp . close ( ) ; return result ; } finally { close With Warni... | public static < T , U extends InputStream > T withStream ( U stream , @ ClosureParams ( value = FirstParam . class ) Closure < T > closure ) throws IOException { try { T result = closure . call ( stream ) ; InputStream temp = stream ; stream = null ; temp . close ( ) ; return result ; } finally { closeWithWarning ( str... | 81 |
java-test-9798 | java | What does the code allow ensuring that it is flushed and closed before this method returns ? | this input stream to be used within the closure | public static < T , U extends Input Stream > T with Stream ( U stream , @ Closure Params ( value = First Param . class ) Closure < T > closure ) throws IO Exception { try { T result = closure . call ( stream ) ; Input Stream temp = stream ; stream = null ; temp . close ( ) ; return result ; } finally { close With Warni... | public static < T , U extends InputStream > T withStream ( U stream , @ ClosureParams ( value = FirstParam . class ) Closure < T > closure ) throws IOException { try { T result = closure . call ( stream ) ; InputStream temp = stream ; stream = null ; temp . close ( ) ; return result ; } finally { closeWithWarning ( str... | 81 |
java-test-9799 | java | How do none return ? | without exception if misspelled or non - existing and for case - insensitivity | public static P Data Partition Format parse P Data Partition Format ( String s ) { if ( s . equals Ignore Case ( STRING ) ) return ROW WISE ; else if ( s . equals Ignore Case ( STRING ) ) return ROW BLOCK WISE ; else if ( s . equals Ignore Case ( STRING ) ) return ROW BLOCK WISE N ; else if ( s . equals Ignore Case ( S... | public static PDataPartitionFormat parsePDataPartitionFormat ( String s ) { if ( s . equalsIgnoreCase ( STRING ) ) return ROW_WISE ; else if ( s . equalsIgnoreCase ( STRING ) ) return ROW_BLOCK_WISE ; else if ( s . equalsIgnoreCase ( STRING ) ) return ROW_BLOCK_WISE_N ; else if ( s . equalsIgnoreCase ( STRING ) ) retur... | 140 |
java-test-9801 | java | What does this method delete ? | a record corresponding to batchid passed | @ Request Mapping ( value = STRING , method = Request Method . DELETE ) @ Response Body public Rest Wrapper delete ( @ Path Variable ( STRING ) Long batch Id , Principal principal ) { Rest Wrapper rest Wrapper = null ; try { File file = new File ( ) ; file . set Batch Id ( batch Id ) ; file DAO . delete ( batch Id ) ; ... | @ RequestMapping ( value = STRING , method = RequestMethod . DELETE ) @ ResponseBody public RestWrapper delete ( @ PathVariable ( STRING ) Long batchId , Principal principal ) { RestWrapper restWrapper = null ; try { File file = new File ( ) ; file . setBatchId ( batchId ) ; fileDAO . delete ( batchId ) ; restWrapper =... | 148 |
java-test-9802 | java | What does this method call proc ? | deletefile | @ Request Mapping ( value = STRING , method = Request Method . DELETE ) @ Response Body public Rest Wrapper delete ( @ Path Variable ( STRING ) Long batch Id , Principal principal ) { Rest Wrapper rest Wrapper = null ; try { File file = new File ( ) ; file . set Batch Id ( batch Id ) ; file DAO . delete ( batch Id ) ; ... | @ RequestMapping ( value = STRING , method = RequestMethod . DELETE ) @ ResponseBody public RestWrapper delete ( @ PathVariable ( STRING ) Long batchId , Principal principal ) { RestWrapper restWrapper = null ; try { File file = new File ( ) ; file . setBatchId ( batchId ) ; fileDAO . delete ( batchId ) ; restWrapper =... | 148 |
java-test-9803 | java | What does the code make ? | a copy of a range of bytes from the passed in data array | public static byte [ ] copy Of Range ( byte [ ] data , int from , int to ) { int new Length = get Length ( from , to ) ; byte [ ] tmp = new byte [ new Length ] ; if ( data . length - from < new Length ) { System . arraycopy ( data , from , tmp , NUM , data . length - from ) ; } else { System . arraycopy ( data , from ,... | public static byte [ ] copyOfRange ( byte [ ] data , int from , int to ) { int newLength = getLength ( from , to ) ; byte [ ] tmp = new byte [ newLength ] ; if ( data . length - from < newLength ) { System . arraycopy ( data , from , tmp , _NUM , data . length - from ) ; } else { System . arraycopy ( data , from , tmp ... | 100 |
java-test-9804 | java | What will be padded with zeroes in which case ? | the return array | public static byte [ ] copy Of Range ( byte [ ] data , int from , int to ) { int new Length = get Length ( from , to ) ; byte [ ] tmp = new byte [ new Length ] ; if ( data . length - from < new Length ) { System . arraycopy ( data , from , tmp , NUM , data . length - from ) ; } else { System . arraycopy ( data , from ,... | public static byte [ ] copyOfRange ( byte [ ] data , int from , int to ) { int newLength = getLength ( from , to ) ; byte [ ] tmp = new byte [ newLength ] ; if ( data . length - from < newLength ) { System . arraycopy ( data , from , tmp , _NUM , data . length - from ) ; } else { System . arraycopy ( data , from , tmp ... | 100 |
java-test-9806 | java | What did the code read ? | any errors from the process | private void wait For Errors ( Write Stream Old error , Input Stream input Stream , Input Stream error Stream ) throws IO Exception { byte [ ] buffer = new byte [ NUM ] ; int stderr Len = NUM ; int stdout Len = NUM ; if ( input Stream == null || error Stream == null ) return ; do { if ( ( stderr Len = error Stream . av... | private void waitForErrors ( WriteStreamOld error , InputStream inputStream , InputStream errorStream ) throws IOException { byte [ ] buffer = new byte [ _NUM ] ; int stderrLen = _NUM ; int stdoutLen = _NUM ; if ( inputStream == null || errorStream == null ) return ; do { if ( ( stderrLen = errorStream . available ( ) ... | 295 |
java-test-9807 | java | Where do rectangles locate ? | in an image | public Rectangle Location Result locate Rectangles ( Mat gray Image ) { Mat gray = gray Image . clone ( ) ; Filter . downsample ( gray , NUM ) ; Filter . upsample ( gray , NUM ) ; Mat cache Hierarchy = new Mat ( ) ; Mat gray Temp = new Mat ( ) ; List < Rectangle > rectangles = new Array List < > ( ) ; List < Contour > ... | public RectangleLocationResult locateRectangles ( Mat grayImage ) { Mat gray = grayImage . clone ( ) ; Filter . downsample ( gray , _NUM ) ; Filter . upsample ( gray , _NUM ) ; Mat cacheHierarchy = new Mat ( ) ; Mat grayTemp = new Mat ( ) ; List < Rectangle > rectangles = new ArrayList < > ( ) ; List < Contour > contou... | 431 |
java-test-9813 | java | Where do the traceback start ? | at a specific level | String traceback ( int level ) { String Buffer sb = new String Buffer ( ) ; sb . append ( STRING ) ; for ( Debug Lib . Call Frame c ; ( c = get Call Frame ( level ++ ) ) != null ; ) { sb . append ( STRING ) ; sb . append ( c . shortsource ( ) ) ; sb . append ( STRING ) ; if ( c . currentline ( ) > NUM ) sb . append ( c... | String traceback ( int level ) { StringBuffer sb = new StringBuffer ( ) ; sb . append ( STRING ) ; for ( DebugLib . CallFrame c ; ( c = getCallFrame ( level ++ ) ) != null ; ) { sb . append ( STRING ) ; sb . append ( c . shortsource ( ) ) ; sb . append ( STRING ) ; if ( c . currentline ( ) > _NUM ) sb . append ( c . cu... | 213 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.