id stringlengths 11 15 | language stringclasses 1
value | 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-4523 | java | What does message provide ? | notice that the operator has started execution and will consume some specific number of binding set chunks | final protected void start Op ( final I Start Op Message msg ) { if ( ! controller ) throw new Unsupported Operation Exception ( ERR NOT CONTROLLER ) ; if ( msg == null ) throw new Illegal Argument Exception ( ) ; if ( ! query Id . equals ( msg . get Query Id ( ) ) ) throw new Illegal Argument Exception ( ) ; lock . lo... | final protected void startOp ( final IStartOpMessage msg ) { if ( ! controller ) throw new UnsupportedOperationException ( ERR_NOT_CONTROLLER ) ; if ( msg == null ) throw new IllegalArgumentException ( ) ; if ( ! queryId . equals ( msg . getQueryId ( ) ) ) throw new IllegalArgumentException ( ) ; lock . lock ( ) ; try ... | 149 |
java-test-4524 | java | When is this method called ? | when new node receives topology from coordinator | public void restore Topology ( Iterable < Tcp Discovery Node > nodes , long top Ver ) { assert ! F . is Empty ( nodes ) ; assert top Ver > NUM ; rw Lock . write Lock ( ) . lock ( ) ; try { loc Node . internal Order ( top Ver ) ; clear ( ) ; boolean first Add = BOOL ; for ( Tcp Discovery Node node : nodes ) { if ( nodes... | public void restoreTopology ( Iterable < TcpDiscoveryNode > nodes , long topVer ) { assert ! F . isEmpty ( nodes ) ; assert topVer > _NUM ; rwLock . writeLock ( ) . lock ( ) ; try { locNode . internalOrder ( topVer ) ; clear ( ) ; boolean firstAdd = _BOOL ; for ( TcpDiscoveryNode node : nodes ) { if ( nodesMap . contai... | 190 |
java-test-4525 | java | When does nodes initialize also ? | last update time | public void restore Topology ( Iterable < Tcp Discovery Node > nodes , long top Ver ) { assert ! F . is Empty ( nodes ) ; assert top Ver > NUM ; rw Lock . write Lock ( ) . lock ( ) ; try { loc Node . internal Order ( top Ver ) ; clear ( ) ; boolean first Add = BOOL ; for ( Tcp Discovery Node node : nodes ) { if ( nodes... | public void restoreTopology ( Iterable < TcpDiscoveryNode > nodes , long topVer ) { assert ! F . isEmpty ( nodes ) ; assert topVer > _NUM ; rwLock . writeLock ( ) . lock ( ) ; try { locNode . internalOrder ( topVer ) ; clear ( ) ; boolean firstAdd = _BOOL ; for ( TcpDiscoveryNode node : nodes ) { if ( nodesMap . contai... | 190 |
java-test-4526 | java | What did new node receive from coordinator when ? | topology | public void restore Topology ( Iterable < Tcp Discovery Node > nodes , long top Ver ) { assert ! F . is Empty ( nodes ) ; assert top Ver > NUM ; rw Lock . write Lock ( ) . lock ( ) ; try { loc Node . internal Order ( top Ver ) ; clear ( ) ; boolean first Add = BOOL ; for ( Tcp Discovery Node node : nodes ) { if ( nodes... | public void restoreTopology ( Iterable < TcpDiscoveryNode > nodes , long topVer ) { assert ! F . isEmpty ( nodes ) ; assert topVer > _NUM ; rwLock . writeLock ( ) . lock ( ) ; try { locNode . internalOrder ( topVer ) ; clear ( ) ; boolean firstAdd = _BOOL ; for ( TcpDiscoveryNode node : nodes ) { if ( nodesMap . contai... | 190 |
java-test-4527 | java | What are remote in this case ? | all nodes received | public void restore Topology ( Iterable < Tcp Discovery Node > nodes , long top Ver ) { assert ! F . is Empty ( nodes ) ; assert top Ver > NUM ; rw Lock . write Lock ( ) . lock ( ) ; try { loc Node . internal Order ( top Ver ) ; clear ( ) ; boolean first Add = BOOL ; for ( Tcp Discovery Node node : nodes ) { if ( nodes... | public void restoreTopology ( Iterable < TcpDiscoveryNode > nodes , long topVer ) { assert ! F . isEmpty ( nodes ) ; assert topVer > _NUM ; rwLock . writeLock ( ) . lock ( ) ; try { locNode . internalOrder ( topVer ) ; clear ( ) ; boolean firstAdd = _BOOL ; for ( TcpDiscoveryNode node : nodes ) { if ( nodesMap . contai... | 190 |
java-test-4528 | java | For what purpose do discovery perform ? | for a storage provider | public Driver Task discover Storage Provider ( Storage Provider storage Provider , List < Storage System > storage Systems ) { Dell SC Driver Task task = new Dell SC Driver Task ( STRING ) ; try { LOG . info ( STRING , storage Provider . get Provider Host ( ) , storage Provider . get Port Number ( ) , storage Provider ... | public DriverTask discoverStorageProvider ( StorageProvider storageProvider , List < StorageSystem > storageSystems ) { DellSCDriverTask task = new DellSCDriverTask ( STRING ) ; try { LOG . info ( STRING , storageProvider . getProviderHost ( ) , storageProvider . getPortNumber ( ) , storageProvider . getUsername ( ) ) ... | 360 |
java-test-4529 | java | What does the code create ? | the gmapsfx model polyline | public void create Underlying ( ) { if ( options != null ) { options . create Underlying ( ) ; if ( Platform . is Fx Application Thread ( ) ) { line = new com . lynden . gmapsfx . shapes . Polyline ( options . convert ( ) ) ; } } } | public void createUnderlying ( ) { if ( options != null ) { options . createUnderlying ( ) ; if ( Platform . isFxApplicationThread ( ) ) { line = new com . lynden . gmapsfx . shapes . Polyline ( options . convert ( ) ) ; } } } | 56 |
java-test-4533 | java | What does the code redo if any has been performed ? | the last action | public void redo ( ) { try { if ( undo Manager . can Redo ( ) ) { undo Manager . redo ( ) ; for ( Key Listener kl : get Key Listeners ( ) ) { kl . key Typed ( null ) ; kl . key Released ( null ) ; } } } catch ( Cannot Redo Exception e ) { } } | public void redo ( ) { try { if ( undoManager . canRedo ( ) ) { undoManager . redo ( ) ; for ( KeyListener kl : getKeyListeners ( ) ) { kl . keyTyped ( null ) ; kl . keyReleased ( null ) ; } } } catch ( CannotRedoException e ) { } } | 68 |
java-test-4534 | java | What does the code separate into an input and output list ? | the recipe | private void add Final ( Object [ ] stacks ) { Object [ ] input = new Object [ input Size ] , output = new Object [ output Size ] ; for ( int i = NUM ; i < stacks . length ; i ++ ) { if ( i < input Size ) { input [ i ] = stacks [ i ] ; } else if ( ! ( i - input Size > output Size ) ) { output [ i - input Size ] = stack... | private void addFinal ( Object [ ] stacks ) { Object [ ] input = new Object [ inputSize ] , output = new Object [ outputSize ] ; for ( int i = _NUM ; i < stacks . length ; i ++ ) { if ( i < inputSize ) { input [ i ] = stacks [ i ] ; } else if ( ! ( i - inputSize > outputSize ) ) { output [ i - inputSize ] = stacks [ i ... | 118 |
java-test-4536 | java | What does the code compute ? | the depth of the graph | protected int max Depth ( Layout . Node node ) { int depth = NUM ; for ( int i = NUM ; i < node . num Children ( ) ; i ++ ) { Layout . Node child = node . get Child ( i ) ; depth = Math . max ( depth , max Depth ( child ) ) ; } return depth + NUM ; } | protected int maxDepth ( Layout . Node node ) { int depth = _NUM ; for ( int i = _NUM ; i < node . numChildren ( ) ; i ++ ) { Layout . Node child = node . getChild ( i ) ; depth = Math . max ( depth , maxDepth ( child ) ) ; } return depth + _NUM ; } | 71 |
java-test-4537 | java | What does the code provide ? | a string representation of whether this connection is closed or not | private String liveness ( ) { boolean is Closed = BOOL ; try { if ( is Closed ( ) ) { is Closed = BOOL ; } } catch ( SQL Exception s ) { is Closed = BOOL ; } if ( is Closed ) { return STRING ; } return STRING ; } | private String liveness ( ) { boolean isClosed = _BOOL ; try { if ( isClosed ( ) ) { isClosed = _BOOL ; } } catch ( SQLException s ) { isClosed = _BOOL ; } if ( isClosed ) { return STRING ; } return STRING ; } | 56 |
java-test-4539 | java | Does another vm write the exact same contents ? | No | private boolean write Jar Bytes To File ( final File file , final byte [ ] jar Bytes ) { final boolean is Debug Enabled = logger . is Debug Enabled ( ) ; try { if ( file . create New File ( ) ) { if ( is Debug Enabled ) { logger . debug ( STRING , file . get Absolute Path ( ) ) ; } final Output Stream out Stream = new ... | private boolean writeJarBytesToFile ( final File file , final byte [ ] jarBytes ) { final boolean isDebugEnabled = logger . isDebugEnabled ( ) ; try { if ( file . createNewFile ( ) ) { if ( isDebugEnabled ) { logger . debug ( STRING , file . getAbsolutePath ( ) ) ; } final OutputStream outStream = new FileOutputStream ... | 146 |
java-test-4540 | java | Do this vm write the contents to the file successfully ? | No | private boolean write Jar Bytes To File ( final File file , final byte [ ] jar Bytes ) { final boolean is Debug Enabled = logger . is Debug Enabled ( ) ; try { if ( file . create New File ( ) ) { if ( is Debug Enabled ) { logger . debug ( STRING , file . get Absolute Path ( ) ) ; } final Output Stream out Stream = new ... | private boolean writeJarBytesToFile ( final File file , final byte [ ] jarBytes ) { final boolean isDebugEnabled = logger . isDebugEnabled ( ) ; try { if ( file . createNewFile ( ) ) { if ( isDebugEnabled ) { logger . debug ( STRING , file . getAbsolutePath ( ) ) ; } final OutputStream outStream = new FileOutputStream ... | 146 |
java-test-4541 | java | What did the code read ? | the specified number of bytes | @ Override public int read ( byte [ ] b , int off , int len ) throws IO Exception { if ( b == null ) { throw new Null Pointer Exception ( STRING ) ; } if ( len < NUM || off < NUM || ( off + len ) > b . length ) { throw new Index Out Of Bounds Exception ( STRING + b . length + STRING + off + STRING + len ) ; } int read ... | @ Override public int read ( byte [ ] b , int off , int len ) throws IOException { if ( b == null ) { throw new NullPointerException ( STRING ) ; } if ( len < _NUM || off < _NUM || ( off + len ) > b . length ) { throw new IndexOutOfBoundsException ( STRING + b . length + STRING + off + STRING + len ) ; } int read = _NU... | 202 |
java-test-4542 | java | What does the code extract from the name ? | the streamid | public static String stream Id From Name ( String name ) { Objects . require Non Null ( name , STRING ) ; if ( ! name . starts With ( ID PREFIX ) ) return null ; return name . substring ( ID PREFIX . length ( ) ) ; } | public static String streamIdFromName ( String name ) { Objects . requireNonNull ( name , STRING ) ; if ( ! name . startsWith ( ID_PREFIX ) ) return null ; return name . substring ( ID_PREFIX . length ( ) ) ; } | 52 |
java-test-4544 | java | What does this check contain ? | a workaround for an issue in aem 6 . 1 , when after the deploy occasionally insert window contains an empty list | public boolean is Displayed Expecting Components ( ) { boolean result = BOOL ; if ( conditions . is Condition Met ( visibility Of ( window ) ) ) { if ( components . is Empty ( ) ) { close Button . click ( ) ; } else { result = BOOL ; } } return result ; } | public boolean isDisplayedExpectingComponents ( ) { boolean result = _BOOL ; if ( conditions . isConditionMet ( visibilityOf ( window ) ) ) { if ( components . isEmpty ( ) ) { closeButton . click ( ) ; } else { result = _BOOL ; } } return result ; } | 60 |
java-test-4545 | java | What does the code calculate ? | the diff for the given revision | protected Diff process Revision ( final Revision revision ) throws Unsupported Encoding Exception { Diff diff = super . process Revision ( revision ) ; if ( diff == null ) { this . ignored Revisions Counter ++ ; } else { this . revision Counter ++ ; this . diff Part Counter += diff . size ( ) ; } return diff ; } | protected Diff processRevision ( final Revision revision ) throws UnsupportedEncodingException { Diff diff = super . processRevision ( revision ) ; if ( diff == null ) { this . ignoredRevisionsCounter ++ ; } else { this . revisionCounter ++ ; this . diffPartCounter += diff . size ( ) ; } return diff ; } | 65 |
java-test-4547 | java | How does a diagram specification ( and a configuration ) save ? | using a stream | private static void save Diagram ( String source , Bean < ? extends Configuration > configuration , Output Stream stream , String encoding ) throws IO Exception , XML Exception { if ( configuration != null ) { Document document = Doc Util . new Document ( ) ; Element root = document . create Element ( STRING ) ; docume... | private static void saveDiagram ( String source , Bean < ? extends Configuration > configuration , OutputStream stream , String encoding ) throws IOException , XMLException { if ( configuration != null ) { Document document = DocUtil . newDocument ( ) ; Element root = document . createElement ( STRING ) ; document . ap... | 204 |
java-test-4548 | java | What does the code make ? | sure co - ords valid and throw exception if not | private static int [ ] validate Coordinates ( int x1 , int y1 , int x2 , int y2 ) { if ( ( x1 > x2 ) | ( y1 < y2 ) ) { if ( x1 > x2 ) { final int temp = x1 ; x1 = x2 ; x2 = temp ; Log Writer . write Log ( STRING ) ; } if ( y1 < y2 ) { final int temp = y1 ; y1 = y2 ; y2 = temp ; Log Writer . write Log ( STRING ) ; } } r... | private static int [ ] validateCoordinates ( int x1 , int y1 , int x2 , int y2 ) { if ( ( x1 > x2 ) | ( y1 < y2 ) ) { if ( x1 > x2 ) { final int temp = x1 ; x1 = x2 ; x2 = temp ; LogWriter . writeLog ( STRING ) ; } if ( y1 < y2 ) { final int temp = y1 ; y1 = y2 ; y2 = temp ; LogWriter . writeLog ( STRING ) ; } } return... | 115 |
java-test-4549 | java | What throw exception ? | co - ords | private static int [ ] validate Coordinates ( int x1 , int y1 , int x2 , int y2 ) { if ( ( x1 > x2 ) | ( y1 < y2 ) ) { if ( x1 > x2 ) { final int temp = x1 ; x1 = x2 ; x2 = temp ; Log Writer . write Log ( STRING ) ; } if ( y1 < y2 ) { final int temp = y1 ; y1 = y2 ; y2 = temp ; Log Writer . write Log ( STRING ) ; } } r... | private static int [ ] validateCoordinates ( int x1 , int y1 , int x2 , int y2 ) { if ( ( x1 > x2 ) | ( y1 < y2 ) ) { if ( x1 > x2 ) { final int temp = x1 ; x1 = x2 ; x2 = temp ; LogWriter . writeLog ( STRING ) ; } if ( y1 < y2 ) { final int temp = y1 ; y1 = y2 ; y2 = temp ; LogWriter . writeLog ( STRING ) ; } } return... | 115 |
java-test-4551 | java | What does the code receive ? | a progressevent | public void update Progress ( Progress Event evt ) { if ( progress Bar != null ) { int type = evt . get Type ( ) ; if ( type == Progress Event . START || type == Progress Event . UPDATE ) { progress Bar . set Visible ( BOOL ) ; progress Bar . set Value ( evt . get Percent Complete ( ) ) ; set Label ( evt . get Task Des... | public void updateProgress ( ProgressEvent evt ) { if ( progressBar != null ) { int type = evt . getType ( ) ; if ( type == ProgressEvent . START || type == ProgressEvent . UPDATE ) { progressBar . setVisible ( _BOOL ) ; progressBar . setValue ( evt . getPercentComplete ( ) ) ; setLabel ( evt . getTaskDescription ( ) )... | 96 |
java-test-4552 | java | How does an input field construct ? | using the specified locale - specific keys for both the caption and the field label | public Input Field Dialog ( final String CAPTION KEY , final String LABEL KEY ) { String caption = I18 n . tr ( CAPTION KEY ) ; Frame frame = GUI Mediator . get App Frame ( ) ; dialog = new J Dialog ( frame , caption , BOOL ) ; dialog . set Size ( NUM , NUM ) ; Labeled Component component = new Labeled Component ( LABE... | public InputFieldDialog ( final String CAPTION_KEY , final String LABEL_KEY ) { String caption = I18n . tr ( CAPTION_KEY ) ; Frame frame = GUIMediator . getAppFrame ( ) ; _dialog = new JDialog ( frame , caption , _BOOL ) ; _dialog . setSize ( _NUM , _NUM ) ; LabeledComponent component = new LabeledComponent ( LABEL_KEY... | 297 |
java-test-4555 | java | What does the code create ? | a spec model | public static Security Spec Model deserialize Spec From File ( String android Project Root Path ) { Security Spec Model spec = null ; String file Name = android Project Root Path + File . separator + Project . OUTPUT DIR + File . separator + SECURITY SPEC SERIAL FILE NAME ; File file = new File ( file Name ) ; if ( fil... | public static SecuritySpecModel deserializeSpecFromFile ( String androidProjectRootPath ) { SecuritySpecModel spec = null ; String fileName = androidProjectRootPath + File . separator + Project . OUTPUT_DIR + File . separator + SECURITY_SPEC_SERIAL_FILE_NAME ; File file = new File ( fileName ) ; if ( file . exists ( ) ... | 160 |
java-test-4556 | java | What does the code read ? | the serialized version of the security specification from a file | public static Security Spec Model deserialize Spec From File ( String android Project Root Path ) { Security Spec Model spec = null ; String file Name = android Project Root Path + File . separator + Project . OUTPUT DIR + File . separator + SECURITY SPEC SERIAL FILE NAME ; File file = new File ( file Name ) ; if ( fil... | public static SecuritySpecModel deserializeSpecFromFile ( String androidProjectRootPath ) { SecuritySpecModel spec = null ; String fileName = androidProjectRootPath + File . separator + Project . OUTPUT_DIR + File . separator + SECURITY_SPEC_SERIAL_FILE_NAME ; File file = new File ( fileName ) ; if ( file . exists ( ) ... | 160 |
java-test-4557 | java | What checks whether a node can be placed at a given position if the passed parameter constellation is satisfied ? | internal helper function | private boolean can Be Placed At Position ( final boolean requires All Bound , final Group Node Var Binding Info binding Info , final Hash Set < I Variable < ? > > known Bound , final Map < I Variable < ? > , Integer > remaining Maybe Bound , int i ) { final Set < I Variable < ? > > left To Be Bound = binding Info . le... | private boolean canBePlacedAtPosition ( final boolean requiresAllBound , final GroupNodeVarBindingInfo bindingInfo , final HashSet < IVariable < ? > > knownBound , final Map < IVariable < ? > , Integer > remainingMaybeBound , int i ) { final Set < IVariable < ? > > leftToBeBound = bindingInfo . leftToBeBound ( knownBou... | 203 |
java-test-4558 | java | What do internal helper function check ? | whether a node can be placed at a given position if the passed parameter constellation is satisfied | private boolean can Be Placed At Position ( final boolean requires All Bound , final Group Node Var Binding Info binding Info , final Hash Set < I Variable < ? > > known Bound , final Map < I Variable < ? > , Integer > remaining Maybe Bound , int i ) { final Set < I Variable < ? > > left To Be Bound = binding Info . le... | private boolean canBePlacedAtPosition ( final boolean requiresAllBound , final GroupNodeVarBindingInfo bindingInfo , final HashSet < IVariable < ? > > knownBound , final Map < IVariable < ? > , Integer > remainingMaybeBound , int i ) { final Set < IVariable < ? > > leftToBeBound = bindingInfo . leftToBeBound ( knownBou... | 203 |
java-test-4559 | java | What does the code add ? | an class name which property values must implement | public final void add Instance Of ( String class Name ) { Reject . if Null ( class Name ) ; String value = class Name . trim ( ) ; if ( ! value . matches ( CLASS RE ) ) { throw new Illegal Argument Exception ( STRING + value + STRING ) ; } instance Of Interfaces . add ( value ) ; } | public final void addInstanceOf ( String className ) { Reject . ifNull ( className ) ; String value = className . trim ( ) ; if ( ! value . matches ( CLASS_RE ) ) { throw new IllegalArgumentException ( STRING + value + STRING ) ; } instanceOfInterfaces . add ( value ) ; } | 67 |
java-test-4564 | java | What requires narrowing ? | a conversion from the type of the node to vartype | protected boolean conversion Requires Narrowing ( Type Mirror var Type , Node node ) { Type Mirror unboxed Var Type = Types Utils . is Boxed Primitive ( var Type ) ? types . unboxed Type ( var Type ) : var Type ; Type Kind unboxed Var Kind = unboxed Var Type . get Kind ( ) ; boolean is Left Narrowable To = unboxed Var ... | protected boolean conversionRequiresNarrowing ( TypeMirror varType , Node node ) { TypeMirror unboxedVarType = TypesUtils . isBoxedPrimitive ( varType ) ? types . unboxedType ( varType ) : varType ; TypeKind unboxedVarKind = unboxedVarType . getKind ( ) ; boolean isLeftNarrowableTo = unboxedVarKind == TypeKind . BYTE |... | 114 |
java-test-4570 | java | What does the code add to the list ? | a contact | public void add Contact ( final String address , final String nickname ) throws Im Exception { if ( null == address ) { throw new Null Pointer Exception ( ) ; } if ( m Manager . get State ( ) == Contact List Manager . BLOCKED LIST LOADED ) { if ( m Manager . is Blocked ( address ) ) { throw new Im Exception ( Im Error ... | public void addContact ( final String address , final String nickname ) throws ImException { if ( null == address ) { throw new NullPointerException ( ) ; } if ( mManager . getState ( ) == ContactListManager . BLOCKED_LIST_LOADED ) { if ( mManager . isBlocked ( address ) ) { throw new ImException ( ImErrorInfo . CANT_A... | 169 |
java-test-4573 | java | How do from memory cache or disk cache or network bitmap ? | load | public Bitmap load Bitmap ( String uri , int req Width , int req Height ) { Bitmap bitmap = load Bitmap From Mem Cache ( uri ) ; if ( bitmap != null ) { Log . d ( TAG , STRING + uri ) ; return bitmap ; } try { bitmap = load Bitmap From Disk Cache ( uri , req Width , req Height ) ; if ( bitmap != null ) { Log . d ( TAG ... | public Bitmap loadBitmap ( String uri , int reqWidth , int reqHeight ) { Bitmap bitmap = loadBitmapFromMemCache ( uri ) ; if ( bitmap != null ) { Log . d ( TAG , STRING + uri ) ; return bitmap ; } try { bitmap = loadBitmapFromDiskCache ( uri , reqWidth , reqHeight ) ; if ( bitmap != null ) { Log . d ( TAG , STRING + ur... | 175 |
java-test-4576 | java | What does the code locate ? | a particular interface within the type ' s object hierarchy | private Type < ? > find Interface ( final Class < ? > the Interface ) { Type < ? > the Interface Type = null ; Linked List < Type < ? > > types = new Linked List < Type < ? > > ( ) ; types . add ( this ) ; while ( the Interface Type == null && ! types . is Empty ( ) ) { Type < ? > current Type = types . remove First ( ... | private Type < ? > findInterface ( final Class < ? > theInterface ) { Type < ? > theInterfaceType = null ; LinkedList < Type < ? > > types = new LinkedList < Type < ? > > ( ) ; types . add ( this ) ; while ( theInterfaceType == null && ! types . isEmpty ( ) ) { Type < ? > currentType = types . removeFirst ( ) ; if ( th... | 173 |
java-test-4577 | java | Where did the last line win ? | in spaces | protected void encode Atom ( Output Stream out Stream , byte data [ ] , int offset , int len ) throws IO Exception { byte a , b = NUM , c = NUM ; int c1 , c2 , c3 , c4 ; a = data [ offset ] ; if ( len > NUM ) { b = data [ offset + NUM ] ; } if ( len > NUM ) { c = data [ offset + NUM ] ; } c1 = ( a > > > NUM ) & NUM ; c... | protected void encodeAtom ( OutputStream outStream , byte data [ ] , int offset , int len ) throws IOException { byte a , b = _NUM , c = _NUM ; int c1 , c2 , c3 , c4 ; a = data [ offset ] ; if ( len > _NUM ) { b = data [ offset + _NUM ] ; } if ( len > _NUM ) { c = data [ offset + _NUM ] ; } c1 = ( a > > > _NUM ) & _NUM... | 195 |
java-test-4578 | java | How are we guarding against that since framework calls this method twice when a change happens ? | by caching the state the first time and avoiding the second call if it is the same status | public void on Wifi Connectivity Changed ( boolean connected , final String network Ssid ) { LOGD ( TAG , STRING + ( connected ? STRING : STRING ) ) ; if ( connected && ! m Wifi Connectivity ) { m Wifi Connectivity = BOOL ; if ( m Cast Manager . is Feature Enabled ( Base Cast Manager . FEATURE WIFI RECONNECT ) ) { m Ca... | public void onWifiConnectivityChanged ( boolean connected , final String networkSsid ) { LOGD ( TAG , STRING + ( connected ? STRING : STRING ) ) ; if ( connected && ! mWifiConnectivity ) { mWifiConnectivity = _BOOL ; if ( mCastManager . isFeatureEnabled ( BaseCastManager . FEATURE_WIFI_RECONNECT ) ) { mCastManager . st... | 107 |
java-test-4579 | java | Why are we guarding against that by caching the state the first time and avoiding the second call if it is the same status ? | since framework calls this method twice when a change happens | public void on Wifi Connectivity Changed ( boolean connected , final String network Ssid ) { LOGD ( TAG , STRING + ( connected ? STRING : STRING ) ) ; if ( connected && ! m Wifi Connectivity ) { m Wifi Connectivity = BOOL ; if ( m Cast Manager . is Feature Enabled ( Base Cast Manager . FEATURE WIFI RECONNECT ) ) { m Ca... | public void onWifiConnectivityChanged ( boolean connected , final String networkSsid ) { LOGD ( TAG , STRING + ( connected ? STRING : STRING ) ) ; if ( connected && ! mWifiConnectivity ) { mWifiConnectivity = _BOOL ; if ( mCastManager . isFeatureEnabled ( BaseCastManager . FEATURE_WIFI_RECONNECT ) ) { mCastManager . st... | 107 |
java-test-4581 | java | What does the code validate ? | the board state | private void validate ( int [ ] [ ] b ) { int found [ ] = { NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM , NUM } ; String Builder bs = new String Builder ( ) ; for ( int r = NUM ; r <= Max R ; r ++ ) { for ( int c = NUM ; c <= Max C ; c ++ ) { found [ b [ r ] [ c ] ] = NUM ; b... | private void validate ( int [ ] [ ] b ) { int found [ ] = { _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM , _NUM } ; StringBuilder bs = new StringBuilder ( ) ; for ( int r = _NUM ; r <= MaxR ; r ++ ) { for ( int c = _NUM ; c <= MaxC ; c ++ ) { found [ b [ r ] [ c... | 169 |
java-test-4582 | java | What does the code load if allowed ? | system properties settings | private static void initialize Settings ( Settings . Builder output , Settings input , boolean load Defaults ) { output . put ( input ) ; if ( use System Properties ( input ) ) { if ( load Defaults ) { for ( String prefix : PROPERTY DEFAULTS PREFIXES ) { output . put Properties ( prefix , System . get Properties ( ) ) ... | private static void initializeSettings ( Settings . Builder output , Settings input , boolean loadDefaults ) { output . put ( input ) ; if ( useSystemProperties ( input ) ) { if ( loadDefaults ) { for ( String prefix : PROPERTY_DEFAULTS_PREFIXES ) { output . putProperties ( prefix , System . getProperties ( ) ) ; } } f... | 108 |
java-test-4583 | java | What does the code write according to result ? | the parity flag | public static void write Parity Flag ( final I Translation Environment environment , final long offset , final Operand Size result Size , final String result , final List < Reil Instruction > instructions ) throws Illegal Argument Exception { Preconditions . check Not Null ( environment , STRING ) ; Preconditions . che... | public static void writeParityFlag ( final ITranslationEnvironment environment , final long offset , final OperandSize resultSize , final String result , final List < ReilInstruction > instructions ) throws IllegalArgumentException { Preconditions . checkNotNull ( environment , STRING ) ; Preconditions . checkNotNull (... | 386 |
java-test-4584 | java | What does this take care ? | of ensuring each argument is enclosed in quotes if required | public static String create Args String ( List < String > args ) { if ( args == null ) { return STRING ; } String Builder args Sb = new String Builder ( ) ; for ( String arg : args ) { if ( ( arg . contains ( STRING ) || arg . contains ( STRING ) ) && ! String Utilities . is Quoted ( arg ) ) { args Sb . append ( String... | public static String createArgsString ( List < String > args ) { if ( args == null ) { return STRING ; } StringBuilder argsSb = new StringBuilder ( ) ; for ( String arg : args ) { if ( ( arg . contains ( STRING ) || arg . contains ( STRING ) ) && ! StringUtilities . isQuoted ( arg ) ) { argsSb . append ( StringUtilitie... | 147 |
java-test-4585 | java | What does the code initialize ? | the values of the gui ratio slider | private void initialize Ratio Slider ( ) { ratio Slider . set Major Tick Spacing ( NUM ) ; ratio Slider . set Minor Tick Spacing ( NUM ) ; ratio Slider . set Paint Ticks ( BOOL ) ; Hashtable < Integer , J Label > label Table = new Hashtable < Integer , J Label > ( ) ; label Table . put ( new Integer ( NUM ) , new J Lab... | private void initializeRatioSlider ( ) { ratioSlider . setMajorTickSpacing ( _NUM ) ; ratioSlider . setMinorTickSpacing ( _NUM ) ; ratioSlider . setPaintTicks ( _BOOL ) ; Hashtable < Integer , JLabel > labelTable = new Hashtable < Integer , JLabel > ( ) ; labelTable . put ( new Integer ( _NUM ) , new JLabel ( STRING ) ... | 178 |
java-test-4586 | java | In which direction does the code select a view ? | from position in the adapter | public boolean select ( int position ) { View v = m All List . get ( position ) ; if ( m Multi Choice Adapter != null ) { perform Vibrate ( ) ; perform Select ( v , position , BOOL ) ; return BOOL ; } return BOOL ; } | public boolean select ( int position ) { View v = mAllList . get ( position ) ; if ( mMultiChoiceAdapter != null ) { performVibrate ( ) ; performSelect ( v , position , _BOOL ) ; return _BOOL ; } return _BOOL ; } | 53 |
java-test-4587 | java | What does this method add ? | a record in userroles table | @ Request Mapping ( value = { STRING , STRING } , method = Request Method . PUT ) @ Response Body public Rest Wrapper insert ( @ Model Attribute ( STRING ) @ Valid User Roles user Roles , Binding Result binding Result , Principal principal ) { Rest Wrapper rest Wrapper = null ; if ( binding Result . has Errors ( ) ) { ... | @ RequestMapping ( value = { STRING , STRING } , method = RequestMethod . PUT ) @ ResponseBody public RestWrapper insert ( @ ModelAttribute ( STRING ) @ Valid UserRoles userRoles , BindingResult bindingResult , Principal principal ) { RestWrapper restWrapper = null ; if ( bindingResult . hasErrors ( ) ) { BindingResult... | 318 |
java-test-4589 | java | What will get the styler that is already at the given offset ? | the inserted character | public Styled String insert ( char ch , int offset ) throws String Index Out Of Bounds Exception { if ( offset < NUM || offset > builder . length ( ) ) { throw new String Index Out Of Bounds Exception ( STRING + offset + STRING ) ; } builder . insert ( offset , ch ) ; return this ; } | public StyledString insert ( char ch , int offset ) throws StringIndexOutOfBoundsException { if ( offset < _NUM || offset > builder . length ( ) ) { throw new StringIndexOutOfBoundsException ( STRING + offset + STRING ) ; } builder . insert ( offset , ch ) ; return this ; } | 64 |
java-test-4590 | java | What will the inserted character get ? | the styler that is already at the given offset | public Styled String insert ( char ch , int offset ) throws String Index Out Of Bounds Exception { if ( offset < NUM || offset > builder . length ( ) ) { throw new String Index Out Of Bounds Exception ( STRING + offset + STRING ) ; } builder . insert ( offset , ch ) ; return this ; } | public StyledString insert ( char ch , int offset ) throws StringIndexOutOfBoundsException { if ( offset < _NUM || offset > builder . length ( ) ) { throw new StringIndexOutOfBoundsException ( STRING + offset + STRING ) ; } builder . insert ( offset , ch ) ; return this ; } | 64 |
java-test-4591 | java | What does the code send ? | a connect request for establishing a tunnel to proxy server | private void send CONNECT Request ( ) throws IO Exception { int port = url . get Port ( ) ; requests . set ( NUM , HTTP CONNECT + STRING + connect Request URI ( url ) + STRING + http Version , null ) ; requests . set If Not Set ( STRING , user Agent ) ; String host = url . get Host ( ) ; if ( port != - NUM && port != u... | private void sendCONNECTRequest ( ) throws IOException { int port = url . getPort ( ) ; requests . set ( _NUM , HTTP_CONNECT + STRING + connectRequestURI ( url ) + STRING + httpVersion , null ) ; requests . setIfNotSet ( STRING , userAgent ) ; String host = url . getHost ( ) ; if ( port != - _NUM && port != url . getDe... | 200 |
java-test-4592 | java | What does the code remove ? | a player movement direction | public void remove Direction ( final Direction dir , final boolean face ) { RP Action action ; int size ; action = new RP Action ( ) ; action . put ( STRING , STRING ) ; action . put ( STRING , - dir . get ( ) ) ; send ( action ) ; directions . remove ( dir ) ; size = directions . size ( ) ; if ( size == NUM ) { action... | public void removeDirection ( final Direction dir , final boolean face ) { RPAction action ; int size ; action = new RPAction ( ) ; action . put ( STRING , STRING ) ; action . put ( STRING , - dir . get ( ) ) ; send ( action ) ; directions . remove ( dir ) ; size = directions . size ( ) ; if ( size == _NUM ) { action =... | 149 |
java-test-4593 | java | What does we have at the rulebasedbreakiterator level ? | one special substitution name , " < ignore > " | protected void handle Special Substitution ( String replace , String replace With , int start Pos , String description ) { if ( replace . equals ( STRING ) ) { if ( replace With . char At ( NUM ) == STRING ) { error ( STRING , start Pos , description ) ; } ignore Chars = Char Set . parse String ( replace With ) ; } } | protected void handleSpecialSubstitution ( String replace , String replaceWith , int startPos , String description ) { if ( replace . equals ( STRING ) ) { if ( replaceWith . charAt ( _NUM ) == STRING ) { error ( STRING , startPos , description ) ; } ignoreChars = CharSet . parseString ( replaceWith ) ; } } | 71 |
java-test-4594 | java | For what purpose can subclasses override this function ? | to add more . | protected void handle Special Substitution ( String replace , String replace With , int start Pos , String description ) { if ( replace . equals ( STRING ) ) { if ( replace With . char At ( NUM ) == STRING ) { error ( STRING , start Pos , description ) ; } ignore Chars = Char Set . parse String ( replace With ) ; } } | protected void handleSpecialSubstitution ( String replace , String replaceWith , int startPos , String description ) { if ( replace . equals ( STRING ) ) { if ( replaceWith . charAt ( _NUM ) == STRING ) { error ( STRING , startPos , description ) ; } ignoreChars = CharSet . parseString ( replaceWith ) ; } } | 71 |
java-test-4595 | java | Where does we have one special substitution name , " < ignore > " ? | at the rulebasedbreakiterator level | protected void handle Special Substitution ( String replace , String replace With , int start Pos , String description ) { if ( replace . equals ( STRING ) ) { if ( replace With . char At ( NUM ) == STRING ) { error ( STRING , start Pos , description ) ; } ignore Chars = Char Set . parse String ( replace With ) ; } } | protected void handleSpecialSubstitution ( String replace , String replaceWith , int startPos , String description ) { if ( replace . equals ( STRING ) ) { if ( replaceWith . charAt ( _NUM ) == STRING ) { error ( STRING , startPos , description ) ; } ignoreChars = CharSet . parseString ( replaceWith ) ; } } | 71 |
java-test-4596 | java | What do i . e have ? | some property beyond just being substitutions | protected void handle Special Substitution ( String replace , String replace With , int start Pos , String description ) { if ( replace . equals ( STRING ) ) { if ( replace With . char At ( NUM ) == STRING ) { error ( STRING , start Pos , description ) ; } ignore Chars = Char Set . parse String ( replace With ) ; } } | protected void handleSpecialSubstitution ( String replace , String replaceWith , int startPos , String description ) { if ( replace . equals ( STRING ) ) { if ( replaceWith . charAt ( _NUM ) == STRING ) { error ( STRING , startPos , description ) ; } ignoreChars = CharSet . parseString ( replaceWith ) ; } } | 71 |
java-test-4597 | java | What is done here ? | any special processing that has to go on beyond that which is done by the normal substitution - processing code | protected void handle Special Substitution ( String replace , String replace With , int start Pos , String description ) { if ( replace . equals ( STRING ) ) { if ( replace With . char At ( NUM ) == STRING ) { error ( STRING , start Pos , description ) ; } ignore Chars = Char Set . parse String ( replace With ) ; } } | protected void handleSpecialSubstitution ( String replace , String replaceWith , int startPos , String description ) { if ( replace . equals ( STRING ) ) { if ( replaceWith . charAt ( _NUM ) == STRING ) { error ( STRING , startPos , description ) ; } ignoreChars = CharSet . parseString ( replaceWith ) ; } } | 71 |
java-test-4598 | java | What have this function defines ? | a protocol for handling substitution names that are " special , " i . e . , that have some property beyond just being substitutions . at the rulebasedbreakiterator level | protected void handle Special Substitution ( String replace , String replace With , int start Pos , String description ) { if ( replace . equals ( STRING ) ) { if ( replace With . char At ( NUM ) == STRING ) { error ( STRING , start Pos , description ) ; } ignore Chars = Char Set . parse String ( replace With ) ; } } | protected void handleSpecialSubstitution ( String replace , String replaceWith , int startPos , String description ) { if ( replace . equals ( STRING ) ) { if ( replaceWith . charAt ( _NUM ) == STRING ) { error ( STRING , startPos , description ) ; } ignoreChars = CharSet . parseString ( replaceWith ) ; } } | 71 |
java-test-4599 | java | How do it use then ? | undisambiguated | public String Use This Var ( String id , String context ) { Sym Tab Entry se = null ; int i = Find Sym ( id , context ) ; if ( i == symtab . size ( ) ) return id ; se = ( Sym Tab Entry ) symtab . element At ( i ) ; if ( se . type == GLOBAL || se . type == PROCESSVAR || se . type == PROCEDUREVAR || se . type == PARAMETE... | public String UseThisVar ( String id , String context ) { SymTabEntry se = null ; int i = FindSym ( id , context ) ; if ( i == symtab . size ( ) ) return id ; se = ( SymTabEntry ) symtab . elementAt ( i ) ; if ( se . type == GLOBAL || se . type == PROCESSVAR || se . type == PROCEDUREVAR || se . type == PARAMETER ) retu... | 119 |
java-test-4600 | java | How do subclasses configure imagereaderloader vector ? | with specific imagereaderloaders | protected void configure Image Reader Loaders ( ) { image Reader Loaders = new Vector < Image Reader Loader > ( ) ; Image Reader Loader idl = ( Image Reader Loader ) Component Factory . create ( STRING ) ; if ( idl != null ) { image Reader Loaders . add ( idl ) ; } else { logger . warning ( STRING ) ; } idl = ( Image R... | protected void configureImageReaderLoaders ( ) { imageReaderLoaders = new Vector < ImageReaderLoader > ( ) ; ImageReaderLoader idl = ( ImageReaderLoader ) ComponentFactory . create ( STRING ) ; if ( idl != null ) { imageReaderLoaders . add ( idl ) ; } else { logger . warning ( STRING ) ; } idl = ( ImageReaderLoader ) C... | 111 |
java-test-4601 | java | What do subclasses configure with specific imagereaderloaders with specific imagereaderloaders ? | imagereaderloader vector | protected void configure Image Reader Loaders ( ) { image Reader Loaders = new Vector < Image Reader Loader > ( ) ; Image Reader Loader idl = ( Image Reader Loader ) Component Factory . create ( STRING ) ; if ( idl != null ) { image Reader Loaders . add ( idl ) ; } else { logger . warning ( STRING ) ; } idl = ( Image R... | protected void configureImageReaderLoaders ( ) { imageReaderLoaders = new Vector < ImageReaderLoader > ( ) ; ImageReaderLoader idl = ( ImageReaderLoader ) ComponentFactory . create ( STRING ) ; if ( idl != null ) { imageReaderLoaders . add ( idl ) ; } else { logger . warning ( STRING ) ; } idl = ( ImageReaderLoader ) C... | 111 |
java-test-4602 | java | What do subclasses use ? | to be able to configure imagereaderloader vector with specific imagereaderloaders . by default , loads geotiffimagereader . loader | protected void configure Image Reader Loaders ( ) { image Reader Loaders = new Vector < Image Reader Loader > ( ) ; Image Reader Loader idl = ( Image Reader Loader ) Component Factory . create ( STRING ) ; if ( idl != null ) { image Reader Loaders . add ( idl ) ; } else { logger . warning ( STRING ) ; } idl = ( Image R... | protected void configureImageReaderLoaders ( ) { imageReaderLoaders = new Vector < ImageReaderLoader > ( ) ; ImageReaderLoader idl = ( ImageReaderLoader ) ComponentFactory . create ( STRING ) ; if ( idl != null ) { imageReaderLoaders . add ( idl ) ; } else { logger . warning ( STRING ) ; } idl = ( ImageReaderLoader ) C... | 111 |
java-test-4606 | java | For what purpose do the matching install_tts_data activity launch ? | so the required tts files are properly installed | private void install Voice Data ( ) { if ( Text Utils . is Empty ( get Engine Name ( ) ) ) return ; Intent intent = new Intent ( Text To Speech . Engine . ACTION INSTALL TTS DATA ) ; intent . add Flags ( Intent . FLAG ACTIVITY NEW TASK ) ; intent . set Package ( get Engine Name ( ) ) ; try { Log . v ( TAG , STRING + in... | private void installVoiceData ( ) { if ( TextUtils . isEmpty ( getEngineName ( ) ) ) return ; Intent intent = new Intent ( TextToSpeech . Engine . ACTION_INSTALL_TTS_DATA ) ; intent . addFlags ( Intent . FLAG_ACTIVITY_NEW_TASK ) ; intent . setPackage ( getEngineName ( ) ) ; try { Log . v ( TAG , STRING + intent . toUri... | 118 |
java-test-4607 | java | What does the code ask to launch the matching install_tts_data activity so the required tts files are properly installed ? | the current default engine | private void install Voice Data ( ) { if ( Text Utils . is Empty ( get Engine Name ( ) ) ) return ; Intent intent = new Intent ( Text To Speech . Engine . ACTION INSTALL TTS DATA ) ; intent . add Flags ( Intent . FLAG ACTIVITY NEW TASK ) ; intent . set Package ( get Engine Name ( ) ) ; try { Log . v ( TAG , STRING + in... | private void installVoiceData ( ) { if ( TextUtils . isEmpty ( getEngineName ( ) ) ) return ; Intent intent = new Intent ( TextToSpeech . Engine . ACTION_INSTALL_TTS_DATA ) ; intent . addFlags ( Intent . FLAG_ACTIVITY_NEW_TASK ) ; intent . setPackage ( getEngineName ( ) ) ; try { Log . v ( TAG , STRING + intent . toUri... | 118 |
java-test-4608 | java | What does the code ask the current default engine ? | to launch the matching install_tts_data activity so the required tts files are properly installed | private void install Voice Data ( ) { if ( Text Utils . is Empty ( get Engine Name ( ) ) ) return ; Intent intent = new Intent ( Text To Speech . Engine . ACTION INSTALL TTS DATA ) ; intent . add Flags ( Intent . FLAG ACTIVITY NEW TASK ) ; intent . set Package ( get Engine Name ( ) ) ; try { Log . v ( TAG , STRING + in... | private void installVoiceData ( ) { if ( TextUtils . isEmpty ( getEngineName ( ) ) ) return ; Intent intent = new Intent ( TextToSpeech . Engine . ACTION_INSTALL_TTS_DATA ) ; intent . addFlags ( Intent . FLAG_ACTIVITY_NEW_TASK ) ; intent . setPackage ( getEngineName ( ) ) ; try { Log . v ( TAG , STRING + intent . toUri... | 118 |
java-test-4609 | java | What does the code add to every method in the stub file ? | a declannotation | private void add Decl Annotations ( Map < String , Set < Annotation Mirror > > decl Annos , Element elt ) { if ( from Stub File != null ) { Set < Annotation Mirror > annos = decl Annos . get ( Element Utils . get Verbose Name ( elt ) ) ; if ( annos == null ) { annos = Annotation Utils . create Annotation Set ( ) ; put ... | private void addDeclAnnotations ( Map < String , Set < AnnotationMirror > > declAnnos , Element elt ) { if ( fromStubFile != null ) { Set < AnnotationMirror > annos = declAnnos . get ( ElementUtils . getVerboseName ( elt ) ) ; if ( annos == null ) { annos = AnnotationUtils . createAnnotationSet ( ) ; putOrAddToMap ( de... | 107 |
java-test-4610 | java | What does the code initialize ? | the raster program | private void init Raster Program ( ) { Int Buffer props = Buffer Utils . create Int Buffer ( NUM ) ; Int Buffer params = Buffer Utils . create Int Buffer ( NUM ) ; int uniforms Resource Index = gl Get Program Resource Index ( raster Program , GL UNIFORM BLOCK , STRING ) ; compute Ubo Binding = params . get ( NUM ) ; pr... | private void initRasterProgram ( ) { IntBuffer props = BufferUtils . createIntBuffer ( _NUM ) ; IntBuffer params = BufferUtils . createIntBuffer ( _NUM ) ; int uniformsResourceIndex = glGetProgramResourceIndex ( rasterProgram , GL_UNIFORM_BLOCK , STRING ) ; computeUboBinding = params . get ( _NUM ) ; props . put ( _NUM... | 114 |
java-test-4611 | java | What will have infinite number of points approaching + / - 90 degrees ? | mercator | public static int convert Latm To Y ( int latm ) { long v = Math . round ( ( Mercator . MAX Y - Mercator . lat 2 y ( latm / LATLON TO LATLONM ) ) * MAX AP UNITS / ( Mercator . MAX Y * NUM ) ) ; if ( v > MAX AP UNITS ) return MAX AP UNITS ; if ( v < NUM ) return - NUM ; return ( int ) v ; } | public static int convertLatmToY ( int latm ) { long v = Math . round ( ( Mercator . MAX_Y - Mercator . lat2y ( latm / LATLON_TO_LATLONM ) ) * MAX_AP_UNITS / ( Mercator . MAX_Y * _NUM ) ) ; if ( v > MAX_AP_UNITS ) return MAX_AP_UNITS ; if ( v < _NUM ) return - _NUM ; return ( int ) v ; } | 83 |
java-test-4612 | java | What do points approach ? | 90 degrees | public static int convert Latm To Y ( int latm ) { long v = Math . round ( ( Mercator . MAX Y - Mercator . lat 2 y ( latm / LATLON TO LATLONM ) ) * MAX AP UNITS / ( Mercator . MAX Y * NUM ) ) ; if ( v > MAX AP UNITS ) return MAX AP UNITS ; if ( v < NUM ) return - NUM ; return ( int ) v ; } | public static int convertLatmToY ( int latm ) { long v = Math . round ( ( Mercator . MAX_Y - Mercator . lat2y ( latm / LATLON_TO_LATLONM ) ) * MAX_AP_UNITS / ( Mercator . MAX_Y * _NUM ) ) ; if ( v > MAX_AP_UNITS ) return MAX_AP_UNITS ; if ( v < _NUM ) return - _NUM ; return ( int ) v ; } | 83 |
java-test-4613 | java | What will mercator have ? | infinite number of points approaching + / - 90 degrees | public static int convert Latm To Y ( int latm ) { long v = Math . round ( ( Mercator . MAX Y - Mercator . lat 2 y ( latm / LATLON TO LATLONM ) ) * MAX AP UNITS / ( Mercator . MAX Y * NUM ) ) ; if ( v > MAX AP UNITS ) return MAX AP UNITS ; if ( v < NUM ) return - NUM ; return ( int ) v ; } | public static int convertLatmToY ( int latm ) { long v = Math . round ( ( Mercator . MAX_Y - Mercator . lat2y ( latm / LATLON_TO_LATLONM ) ) * MAX_AP_UNITS / ( Mercator . MAX_Y * _NUM ) ) ; if ( v > MAX_AP_UNITS ) return MAX_AP_UNITS ; if ( v < _NUM ) return - _NUM ; return ( int ) v ; } | 83 |
java-test-4614 | java | What does the code guess ? | the content type based on the provided char sequence | public static X Content Type x Content Type ( Char Sequence content ) { int length = content . length ( ) < GUESS HEADER LENGTH ? content . length ( ) : GUESS HEADER LENGTH ; if ( length == NUM ) { return null ; } char first = content . char At ( NUM ) ; if ( first == STRING ) { return X Content Type . JSON ; } if ( le... | public static XContentType xContentType ( CharSequence content ) { int length = content . length ( ) < GUESS_HEADER_LENGTH ? content . length ( ) : GUESS_HEADER_LENGTH ; if ( length == _NUM ) { return null ; } char first = content . charAt ( _NUM ) ; if ( first == STRING ) { return XContentType . JSON ; } if ( length >... | 229 |
java-test-4616 | java | For what purpose would only smsnotificationmanager be calling this method ? | to register itself | public void register Callback Handler ( SMS Object Listener change Listener ) throws SMS Exception { object Listener = change Listener ; if ( ! notification Initialized ) { String notification Flag = System Properties . get ( NOTIFICATION PROPERTY , STRING ) ; if ( notification Flag . equals Ignore Case ( STRING ) ) { ... | public void registerCallbackHandler ( SMSObjectListener changeListener ) throws SMSException { objectListener = changeListener ; if ( ! notificationInitialized ) { String notificationFlag = SystemProperties . get ( NOTIFICATION_PROPERTY , STRING ) ; if ( notificationFlag . equalsIgnoreCase ( STRING ) ) { try { URL url ... | 208 |
java-test-4617 | java | When were computefibuffer and computecurrentpi called ? | before this method | protected double current Score Function ( ) { double score = NUM ; for ( int i = NUM ; i < this . values [ this . current Var 1 ] . length ; i ++ ) { for ( int j = NUM ; j < this . values [ this . current Var 2 ] . length ; j ++ ) { score -= this . current Counts [ this . current Var 1 ] [ this . current Var 2 ] [ i ] ... | protected double currentScoreFunction ( ) { double score = _NUM ; for ( int i = _NUM ; i < this . values [ this . currentVar1 ] . length ; i ++ ) { for ( int j = _NUM ; j < this . values [ this . currentVar2 ] . length ; j ++ ) { score -= this . currentCounts [ this . currentVar1 ] [ this . currentVar2 ] [ i ] [ j ] * ... | 114 |
java-test-4618 | java | What does the code close ? | the connection to the database | public void close Connection ( ) { try { if ( m connection != null ) { m connection . close ( ) ; } } catch ( final SQL Exception exception ) { Navi Logger . severe ( STRING , exception ) ; } m connection = null ; } | public void closeConnection ( ) { try { if ( m_connection != null ) { m_connection . close ( ) ; } } catch ( final SQLException exception ) { NaviLogger . severe ( STRING , exception ) ; } m_connection = null ; } | 51 |
java-test-4621 | java | What does this create ? | a persistent collection reader and pipeline | @ Override public final boolean has Next ( ) throws IO Exception , Collection Exception { while ( ! shutting Down ) { monitor . start Function Trace ( STRING ) ; boolean next = do Has Next ( ) ; monitor . finish Function Trace ( STRING ) ; if ( next ) { return BOOL ; } try { Thread . sleep ( sleep Delay ) ; } catch ( I... | @ Override public final boolean hasNext ( ) throws IOException , CollectionException { while ( ! shuttingDown ) { monitor . startFunctionTrace ( STRING ) ; boolean next = doHasNext ( ) ; monitor . finishFunctionTrace ( STRING ) ; if ( next ) { return _BOOL ; } try { Thread . sleep ( sleepDelay ) ; } catch ( Interrupted... | 87 |
java-test-4622 | java | Till when do the uima hasnext ( ) method check for new documents continuously ? | until one is found | @ Override public final boolean has Next ( ) throws IO Exception , Collection Exception { while ( ! shutting Down ) { monitor . start Function Trace ( STRING ) ; boolean next = do Has Next ( ) ; monitor . finish Function Trace ( STRING ) ; if ( next ) { return BOOL ; } try { Thread . sleep ( sleep Delay ) ; } catch ( I... | @ Override public final boolean hasNext ( ) throws IOException , CollectionException { while ( ! shuttingDown ) { monitor . startFunctionTrace ( STRING ) ; boolean next = doHasNext ( ) ; monitor . finishFunctionTrace ( STRING ) ; if ( next ) { return _BOOL ; } try { Thread . sleep ( sleepDelay ) ; } catch ( Interrupted... | 87 |
java-test-4623 | java | What does this prevent from exiting unless asked to ? | the collection reader | @ Override public final boolean has Next ( ) throws IO Exception , Collection Exception { while ( ! shutting Down ) { monitor . start Function Trace ( STRING ) ; boolean next = do Has Next ( ) ; monitor . finish Function Trace ( STRING ) ; if ( next ) { return BOOL ; } try { Thread . sleep ( sleep Delay ) ; } catch ( I... | @ Override public final boolean hasNext ( ) throws IOException , CollectionException { while ( ! shuttingDown ) { monitor . startFunctionTrace ( STRING ) ; boolean next = doHasNext ( ) ; monitor . finishFunctionTrace ( STRING ) ; if ( next ) { return _BOOL ; } try { Thread . sleep ( sleepDelay ) ; } catch ( Interrupted... | 87 |
java-test-4624 | java | What does the code add ? | wlst dependencies | private void add Wlst Arguments ( Jvm Launcher java ) { File server Dir = new File ( get Weblogic Home ( ) , STRING ) ; java . add Classpath Entries ( new File ( server Dir , STRING ) ) ; java . set Main Class ( STRING ) ; } | private void addWlstArguments ( JvmLauncher java ) { File serverDir = new File ( getWeblogicHome ( ) , STRING ) ; java . addClasspathEntries ( new File ( serverDir , STRING ) ) ; java . setMainClass ( STRING ) ; } | 53 |
java-test-4625 | java | What does the code reopen if the database is already read - write in read - write mode ? | the database | public void reopen Read Write ( ) { synchronized ( m Lock ) { throw If Not Open Locked ( ) ; if ( ! is Read Only Locked ( ) ) { return ; } final int old Open Flags = m Configuration Locked . open Flags ; m Configuration Locked . open Flags = ( m Configuration Locked . open Flags & ~ OPEN READ MASK ) | OPEN READWRITE ; ... | public void reopenReadWrite ( ) { synchronized ( mLock ) { throwIfNotOpenLocked ( ) ; if ( ! isReadOnlyLocked ( ) ) { return ; } final int oldOpenFlags = mConfigurationLocked . openFlags ; mConfigurationLocked . openFlags = ( mConfigurationLocked . openFlags & ~ OPEN_READ_MASK ) | OPEN_READWRITE ; try { mConnectionPool... | 112 |
java-test-4626 | java | When is the database does read ? | already | public void reopen Read Write ( ) { synchronized ( m Lock ) { throw If Not Open Locked ( ) ; if ( ! is Read Only Locked ( ) ) { return ; } final int old Open Flags = m Configuration Locked . open Flags ; m Configuration Locked . open Flags = ( m Configuration Locked . open Flags & ~ OPEN READ MASK ) | OPEN READWRITE ; ... | public void reopenReadWrite ( ) { synchronized ( mLock ) { throwIfNotOpenLocked ( ) ; if ( ! isReadOnlyLocked ( ) ) { return ; } final int oldOpenFlags = mConfigurationLocked . openFlags ; mConfigurationLocked . openFlags = ( mConfigurationLocked . openFlags & ~ OPEN_READ_MASK ) | OPEN_READWRITE ; try { mConnectionPool... | 112 |
java-test-4627 | java | Did the code do nothing if the database is already read - write ? | No | public void reopen Read Write ( ) { synchronized ( m Lock ) { throw If Not Open Locked ( ) ; if ( ! is Read Only Locked ( ) ) { return ; } final int old Open Flags = m Configuration Locked . open Flags ; m Configuration Locked . open Flags = ( m Configuration Locked . open Flags & ~ OPEN READ MASK ) | OPEN READWRITE ; ... | public void reopenReadWrite ( ) { synchronized ( mLock ) { throwIfNotOpenLocked ( ) ; if ( ! isReadOnlyLocked ( ) ) { return ; } final int oldOpenFlags = mConfigurationLocked . openFlags ; mConfigurationLocked . openFlags = ( mConfigurationLocked . openFlags & ~ OPEN_READ_MASK ) | OPEN_READWRITE ; try { mConnectionPool... | 112 |
java-test-4628 | java | How does the code reopen the database if the database is already read - write ? | in read - write mode | public void reopen Read Write ( ) { synchronized ( m Lock ) { throw If Not Open Locked ( ) ; if ( ! is Read Only Locked ( ) ) { return ; } final int old Open Flags = m Configuration Locked . open Flags ; m Configuration Locked . open Flags = ( m Configuration Locked . open Flags & ~ OPEN READ MASK ) | OPEN READWRITE ; ... | public void reopenReadWrite ( ) { synchronized ( mLock ) { throwIfNotOpenLocked ( ) ; if ( ! isReadOnlyLocked ( ) ) { return ; } final int oldOpenFlags = mConfigurationLocked . openFlags ; mConfigurationLocked . openFlags = ( mConfigurationLocked . openFlags & ~ OPEN_READ_MASK ) | OPEN_READWRITE ; try { mConnectionPool... | 112 |
java-test-4629 | java | What does the code convert into a set of equivalent virtual files ? | a set of io files | private static Collection < Virtual File > convert File Set ( @ Not Null Collection < File > file Set ) { Collection < Virtual File > result = Lists . new Array List With Capacity ( file Set . size ( ) ) ; Local File System file System = Local File System . get Instance ( ) ; for ( File file : file Set ) { Virtual File... | private static Collection < VirtualFile > convertFileSet ( @ NotNull Collection < File > fileSet ) { Collection < VirtualFile > result = Lists . newArrayListWithCapacity ( fileSet . size ( ) ) ; LocalFileSystem fileSystem = LocalFileSystem . getInstance ( ) ; for ( File file : fileSet ) { VirtualFile virtualFile = file... | 108 |
java-test-4632 | java | What did we try ? | to execute some blob updates one by one in non - autocommit mode | public void test Set String ( ) throws Exception { connection . set Auto Commit ( BOOL ) ; Prepared Statement stmt = connection . prepare Statement ( STRING ) ; try { stmt . set Int ( NUM , NUM ) ; stmt . set String ( NUM , TEST TEXT ) ; stmt . execute Update ( ) ; connection . commit ( ) ; stmt . set Int ( NUM , NUM )... | public void testSetString ( ) throws Exception { connection . setAutoCommit ( _BOOL ) ; PreparedStatement stmt = connection . prepareStatement ( STRING ) ; try { stmt . setInt ( _NUM , _NUM ) ; stmt . setString ( _NUM , TEST_TEXT ) ; stmt . executeUpdate ( ) ; connection . commit ( ) ; stmt . setInt ( _NUM , _NUM ) ; s... | 155 |
java-test-4633 | java | What do we execute one by one one by one ? | some blob updates | public void test Set String ( ) throws Exception { connection . set Auto Commit ( BOOL ) ; Prepared Statement stmt = connection . prepare Statement ( STRING ) ; try { stmt . set Int ( NUM , NUM ) ; stmt . set String ( NUM , TEST TEXT ) ; stmt . execute Update ( ) ; connection . commit ( ) ; stmt . set Int ( NUM , NUM )... | public void testSetString ( ) throws Exception { connection . setAutoCommit ( _BOOL ) ; PreparedStatement stmt = connection . prepareStatement ( STRING ) ; try { stmt . setInt ( _NUM , _NUM ) ; stmt . setString ( _NUM , TEST_TEXT ) ; stmt . executeUpdate ( ) ; connection . commit ( ) ; stmt . setInt ( _NUM , _NUM ) ; s... | 155 |
java-test-4634 | java | When is transaction started ? | before the blob is created | public void test Set String ( ) throws Exception { connection . set Auto Commit ( BOOL ) ; Prepared Statement stmt = connection . prepare Statement ( STRING ) ; try { stmt . set Int ( NUM , NUM ) ; stmt . set String ( NUM , TEST TEXT ) ; stmt . execute Update ( ) ; connection . commit ( ) ; stmt . set Int ( NUM , NUM )... | public void testSetString ( ) throws Exception { connection . setAutoCommit ( _BOOL ) ; PreparedStatement stmt = connection . prepareStatement ( STRING ) ; try { stmt . setInt ( _NUM , _NUM ) ; stmt . setString ( _NUM , TEST_TEXT ) ; stmt . executeUpdate ( ) ; connection . commit ( ) ; stmt . setInt ( _NUM , _NUM ) ; s... | 155 |
java-test-4635 | java | When did the bug find ? | when longvarchar column is used | public void test Set String ( ) throws Exception { connection . set Auto Commit ( BOOL ) ; Prepared Statement stmt = connection . prepare Statement ( STRING ) ; try { stmt . set Int ( NUM , NUM ) ; stmt . set String ( NUM , TEST TEXT ) ; stmt . execute Update ( ) ; connection . commit ( ) ; stmt . set Int ( NUM , NUM )... | public void testSetString ( ) throws Exception { connection . setAutoCommit ( _BOOL ) ; PreparedStatement stmt = connection . prepareStatement ( STRING ) ; try { stmt . setInt ( _NUM , _NUM ) ; stmt . setString ( _NUM , TEST_TEXT ) ; stmt . executeUpdate ( ) ; connection . commit ( ) ; stmt . setInt ( _NUM , _NUM ) ; s... | 155 |
java-test-4636 | java | For what purpose was this test created initially ? | to find the bug when longvarchar column is used | public void test Set String ( ) throws Exception { connection . set Auto Commit ( BOOL ) ; Prepared Statement stmt = connection . prepare Statement ( STRING ) ; try { stmt . set Int ( NUM , NUM ) ; stmt . set String ( NUM , TEST TEXT ) ; stmt . execute Update ( ) ; connection . commit ( ) ; stmt . set Int ( NUM , NUM )... | public void testSetString ( ) throws Exception { connection . setAutoCommit ( _BOOL ) ; PreparedStatement stmt = connection . prepareStatement ( STRING ) ; try { stmt . setInt ( _NUM , _NUM ) ; stmt . setString ( _NUM , TEST_TEXT ) ; stmt . executeUpdate ( ) ; connection . commit ( ) ; stmt . setInt ( _NUM , _NUM ) ; s... | 155 |
java-test-4637 | java | What did it reveal ? | the bug with blobs | public void test Set String ( ) throws Exception { connection . set Auto Commit ( BOOL ) ; Prepared Statement stmt = connection . prepare Statement ( STRING ) ; try { stmt . set Int ( NUM , NUM ) ; stmt . set String ( NUM , TEST TEXT ) ; stmt . execute Update ( ) ; connection . commit ( ) ; stmt . set Int ( NUM , NUM )... | public void testSetString ( ) throws Exception { connection . setAutoCommit ( _BOOL ) ; PreparedStatement stmt = connection . prepareStatement ( STRING ) ; try { stmt . setInt ( _NUM , _NUM ) ; stmt . setString ( _NUM , TEST_TEXT ) ; stmt . executeUpdate ( ) ; connection . commit ( ) ; stmt . setInt ( _NUM , _NUM ) ; s... | 155 |
java-test-4638 | java | What does the code extract from the given path ? | the collection name | public static String extract Collection From Path ( String path ) { String extracted Collection Name = null ; String path Modified = remove From End Of String ( path , SLASH ) ; String [ ] path Segments = path Modified . split ( STRING ) ; if ( path Segments . length > NUM ) { extracted Collection Name = path Segments ... | public static String extractCollectionFromPath ( String path ) { String extractedCollectionName = null ; String pathModified = removeFromEndOfString ( path , SLASH ) ; String [ ] pathSegments = pathModified . split ( STRING ) ; if ( pathSegments . length > _NUM ) { extractedCollectionName = pathSegments [ pathSegments ... | 80 |
java-test-4639 | java | Where did we break ? | on vertical lines and spaces | private void copy To Arrays ( ) { color Extracted = pdf data . is Color Extracted ( ) ; final int count = pdf data . get Raw Text Element Count ( ) ; is Used = new boolean [ count ] ; font Size = new int [ count ] ; writing Mode = new int [ count ] ; space Width = new float [ count ] ; content = new String Builder [ co... | private void copyToArrays ( ) { colorExtracted = pdf_data . isColorExtracted ( ) ; final int count = pdf_data . getRawTextElementCount ( ) ; isUsed = new boolean [ count ] ; fontSize = new int [ count ] ; writingMode = new int [ count ] ; spaceWidth = new float [ count ] ; content = new StringBuilder [ count ] ; textLe... | 309 |
java-test-4640 | java | For what purpose did the code put raw data into arrays if we break on vertical lines and spaces ? | for quick merging | private void copy To Arrays ( ) { color Extracted = pdf data . is Color Extracted ( ) ; final int count = pdf data . get Raw Text Element Count ( ) ; is Used = new boolean [ count ] ; font Size = new int [ count ] ; writing Mode = new int [ count ] ; space Width = new float [ count ] ; content = new String Builder [ co... | private void copyToArrays ( ) { colorExtracted = pdf_data . isColorExtracted ( ) ; final int count = pdf_data . getRawTextElementCount ( ) ; isUsed = new boolean [ count ] ; fontSize = new int [ count ] ; writingMode = new int [ count ] ; spaceWidth = new float [ count ] ; content = new StringBuilder [ count ] ; textLe... | 309 |
java-test-4642 | java | What does the code initialize ? | a new tokenizer instance with a grammar to analyze csv or tsv content | public CSV Tokenizer ( char separator ) { add Joined Type ( CSV Token Type . TEXT ) ; add Ignored Type ( CSV Token Type . QUOTE ) ; put Rules ( new Rule ( STRING , CSV Token Type . ROW SEPARATOR ) , new Rule ( Pattern . quote ( String . value Of ( separator ) ) , CSV Token Type . COLUMN SEPARATOR ) , new Rule ( STRING ... | public CSVTokenizer ( char separator ) { addJoinedType ( CSVTokenType . TEXT ) ; addIgnoredType ( CSVTokenType . QUOTE ) ; putRules ( new Rule ( STRING , CSVTokenType . ROW_SEPARATOR ) , new Rule ( Pattern . quote ( String . valueOf ( separator ) ) , CSVTokenType . COLUMN_SEPARATOR ) , new Rule ( STRING , CSVTokenType ... | 155 |
java-test-4643 | java | What does the code update with the new settings ? | the given avd | @ Nullable public Avd Info create Or Update Avd ( @ Nullable Avd Info current Info , @ Not Null String avd Name , @ Not Null Device device , @ Not Null System Image Description system Image Description , @ Not Null Screen Orientation orientation , boolean is Circular , @ Nullable String sd Card , @ Nullable File skin F... | @ Nullable public AvdInfo createOrUpdateAvd ( @ Nullable AvdInfo currentInfo , @ NotNull String avdName , @ NotNull Device device , @ NotNull SystemImageDescription systemImageDescription , @ NotNull ScreenOrientation orientation , boolean isCircular , @ Nullable String sdCard , @ Nullable File skinFolder , @ NotNull M... | 467 |
java-test-4644 | java | What does the code create ? | the socket implementation | void create Impl ( boolean stream ) throws Socket Exception { if ( impl == null ) set Impl ( ) ; try { impl . create ( stream ) ; created = BOOL ; } catch ( IO Exception e ) { throw new Socket Exception ( e . get Message ( ) ) ; } } | void createImpl ( boolean stream ) throws SocketException { if ( impl == null ) setImpl ( ) ; try { impl . create ( stream ) ; created = _BOOL ; } catch ( IOException e ) { throw new SocketException ( e . getMessage ( ) ) ; } } | 58 |
java-test-4645 | java | How do the given tasklist populate the code ? | with tasks | private void populate Task List ( Volume source , Map < Block Mirror , Volume > group Mirror Source Map , Task List task List , String task Id , Resource Operation Type Enum operation Type ) { Set < URI > group Set = new Hash Set < URI > ( ) ; add Task ( task List , source , task Id , operation Type ) ; for ( Entry < B... | private void populateTaskList ( Volume source , Map < BlockMirror , Volume > groupMirrorSourceMap , TaskList taskList , String taskId , ResourceOperationTypeEnum operationType ) { Set < URI > groupSet = new HashSet < URI > ( ) ; addTask ( taskList , source , taskId , operationType ) ; for ( Entry < BlockMirror , Volume... | 203 |
java-test-4646 | java | What does the code populate ? | an instance of host with the provided host parameter | private void populate Host Data ( Host host , Host Param param ) { if ( param . get Name ( ) != null ) { host . set Label ( param . get Name ( ) ) ; } if ( param . get Host Name ( ) != null ) { host . set Host Name ( param . get Host Name ( ) ) ; } if ( param . get Cluster ( ) != null ) { host . set Cluster ( param . g... | private void populateHostData ( Host host , HostParam param ) { if ( param . getName ( ) != null ) { host . setLabel ( param . getName ( ) ) ; } if ( param . getHostName ( ) != null ) { host . setHostName ( param . getHostName ( ) ) ; } if ( param . getCluster ( ) != null ) { host . setCluster ( param . getCluster ( ) ... | 532 |
java-test-4647 | java | What did the code read ? | the frames read from bytebuffer upto size | protected void read Frames ( Byte Buffer byte Buffer , int size ) { ID 3 v 23 Frame next ; frame Map = new Linked Hash Map ( ) ; encrypted Frame Map = new Linked Hash Map ( ) ; this . file Read Size = size ; logger . finest ( get Logging Filename ( ) + STRING + byte Buffer . position ( ) + STRING + size ) ; while ( byt... | protected void readFrames ( ByteBuffer byteBuffer , int size ) { ID3v23Frame next ; frameMap = new LinkedHashMap ( ) ; encryptedFrameMap = new LinkedHashMap ( ) ; this . fileReadSize = size ; logger . finest ( getLoggingFilename ( ) + STRING + byteBuffer . position ( ) + STRING + size ) ; while ( byteBuffer . position ... | 340 |
java-test-4648 | java | What replaces in the list of violating tuples with missing values ? | violating entries ( w . r . t fds ) | public void replace FD Violating Tuples With Missing ( ) { for ( String premise : F Ds . key Set ( ) ) { Array List < Integer > attr Indexes = new Array List < Integer > ( ) ; attr Indexes . add ( Integer . parse Int ( premise ) ) ; for ( String RHS : F Ds . get ( premise ) ) { attr Indexes . add ( Integer . parse Int ... | public void replaceFDViolatingTuplesWithMissing ( ) { for ( String premise : FDs . keySet ( ) ) { ArrayList < Integer > attrIndexes = new ArrayList < Integer > ( ) ; attrIndexes . add ( Integer . parseInt ( premise ) ) ; for ( String RHS : FDs . get ( premise ) ) { attrIndexes . add ( Integer . parseInt ( RHS ) ) ; } s... | 104 |
java-test-4649 | java | What does violating entries ( w . r . t fds ) replace ? | in the list of violating tuples with missing values | public void replace FD Violating Tuples With Missing ( ) { for ( String premise : F Ds . key Set ( ) ) { Array List < Integer > attr Indexes = new Array List < Integer > ( ) ; attr Indexes . add ( Integer . parse Int ( premise ) ) ; for ( String RHS : F Ds . get ( premise ) ) { attr Indexes . add ( Integer . parse Int ... | public void replaceFDViolatingTuplesWithMissing ( ) { for ( String premise : FDs . keySet ( ) ) { ArrayList < Integer > attrIndexes = new ArrayList < Integer > ( ) ; attrIndexes . add ( Integer . parseInt ( premise ) ) ; for ( String RHS : FDs . get ( premise ) ) { attrIndexes . add ( Integer . parseInt ( RHS ) ) ; } s... | 104 |
java-test-4650 | java | What does the code check ? | the integration span | protected void sanity Checks ( final ODE State initial State , final double t ) throws Math Illegal Argument Exception { final double threshold = NUM * Fast Math . ulp ( Fast Math . max ( Fast Math . abs ( initial State . get Time ( ) ) , Fast Math . abs ( t ) ) ) ; final double dt = Fast Math . abs ( initial State . g... | protected void sanityChecks ( final ODEState initialState , final double t ) throws MathIllegalArgumentException { final double threshold = _NUM * FastMath . ulp ( FastMath . max ( FastMath . abs ( initialState . getTime ( ) ) , FastMath . abs ( t ) ) ) ; final double dt = FastMath . abs ( initialState . getTime ( ) - ... | 113 |
java-test-4651 | java | What does the code write ? | a field . superclasses will be considered | public static void write Field ( final Object target , final String field Name , final Object value , final boolean force Access ) throws Illegal Access Exception { if ( target == null ) { throw new Illegal Argument Exception ( STRING ) ; } Class < ? > cls = target . get Class ( ) ; Field field = Field Utils . get Fiel... | public static void writeField ( final Object target , final String fieldName , final Object value , final boolean forceAccess ) throws IllegalAccessException { if ( target == null ) { throw new IllegalArgumentException ( STRING ) ; } Class < ? > cls = target . getClass ( ) ; Field field = FieldUtils . getField ( cls , ... | 120 |
java-test-4652 | java | When does the code perform forward dct in place ? | for n x n matrix | public void fwd Dct In Place Nx N ( double [ ] [ ] coeffs ) { int u = NUM ; int v = NUM ; double two over sqrtncolsnrows = NUM / Math . sqrt ( ( double ) this . N * this . M ) ; for ( u = NUM ; u <= this . M - NUM ; u ++ ) { fct No Scale ( coeffs [ u ] ) ; } for ( v = NUM ; v <= this . N - NUM ; v ++ ) { for ( u = NUM ... | public void fwdDctInPlaceNxN ( double [ ] [ ] coeffs ) { int u = _NUM ; int v = _NUM ; double two_over_sqrtncolsnrows = _NUM / Math . sqrt ( ( double ) this . N * this . M ) ; for ( u = _NUM ; u <= this . M - _NUM ; u ++ ) { fctNoScale ( coeffs [ u ] ) ; } for ( v = _NUM ; v <= this . N - _NUM ; v ++ ) { for ( u = _NUM... | 183 |
java-test-4655 | java | What does the code fill with classes in the specified directory ? | the class cache | protected void init From Dir ( String prefix , File dir ) { File [ ] files ; files = dir . list Files ( new Class File Filter ( ) ) ; for ( File file : files ) { if ( prefix == null ) { add ( file . get Name ( ) ) ; } else { add ( prefix + STRING + file . get Name ( ) ) ; } } files = dir . list Files ( new Directory Fi... | protected void initFromDir ( String prefix , File dir ) { File [ ] files ; files = dir . listFiles ( new ClassFileFilter ( ) ) ; for ( File file : files ) { if ( prefix == null ) { add ( file . getName ( ) ) ; } else { add ( prefix + STRING + file . getName ( ) ) ; } } files = dir . listFiles ( new DirectoryFilter ( ) ... | 144 |
java-test-4656 | java | What does this default implementation print just ( i . e . < attribute name > < comparison operator > < item value > ) ? | the attribute name and ( optionally ) frequency information | @ Override public String to String ( boolean freq ) { String Buffer result = new String Buffer ( ) ; result . append ( m attribute . name ( ) + STRING ) ; switch ( m comparison ) { case EQUAL : result . append ( STRING ) ; break ; case LESS THAN OR EQUAL TO : result . append ( STRING ) ; break ; case GREATER THAN : res... | @ Override public String toString ( boolean freq ) { StringBuffer result = new StringBuffer ( ) ; result . append ( m_attribute . name ( ) + STRING ) ; switch ( m_comparison ) { case EQUAL : result . append ( STRING ) ; break ; case LESS_THAN_OR_EQUAL_TO : result . append ( STRING ) ; break ; case GREATER_THAN : result... | 132 |
java-test-4657 | java | When does this default implementation print the attribute name and ( optionally ) frequency information just ? | ( i . e . < attribute name > < comparison operator > < item value > ) | @ Override public String to String ( boolean freq ) { String Buffer result = new String Buffer ( ) ; result . append ( m attribute . name ( ) + STRING ) ; switch ( m comparison ) { case EQUAL : result . append ( STRING ) ; break ; case LESS THAN OR EQUAL TO : result . append ( STRING ) ; break ; case GREATER THAN : res... | @ Override public String toString ( boolean freq ) { StringBuffer result = new StringBuffer ( ) ; result . append ( m_attribute . name ( ) + STRING ) ; switch ( m_comparison ) { case EQUAL : result . append ( STRING ) ; break ; case LESS_THAN_OR_EQUAL_TO : result . append ( STRING ) ; break ; case GREATER_THAN : result... | 132 |
java-test-4658 | java | What does the code create ? | the diphoneunitdatabase from the given input stream | public Diphone Unit Database ( URL url , boolean is Binary ) throws IO Exception { if ( ! use Indexing || use Cache ) { diphone Map = new Linked Hash Map ( ) ; } Input Stream is = Utilities . get Input Stream ( url ) ; index Name = get Index Name ( url . to String ( ) ) ; if ( is Binary ) { load Binary ( is ) ; } else ... | public DiphoneUnitDatabase ( URL url , boolean isBinary ) throws IOException { if ( ! useIndexing || useCache ) { diphoneMap = new LinkedHashMap ( ) ; } InputStream is = Utilities . getInputStream ( url ) ; indexName = getIndexName ( url . toString ( ) ) ; if ( isBinary ) { loadBinary ( is ) ; } else { loadText ( is ) ... | 119 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.