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-9814 | java | What does the code get ? | the traceback starting 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 |
java-test-9815 | java | What is starting at a specific level ? | the traceback | 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 |
java-test-9818 | java | What does the code read from the given position ? | the sort order info from the given buffer | static Sort Order read Sort Order ( Byte Buffer buffer , int position , Jet Format format ) { short value = buffer . get Short ( position ) ; byte version = NUM ; if ( format . SIZE SORT ORDER == NUM ) { version = buffer . get ( position + NUM ) ; } if ( value == NUM ) { return format . DEFAULT SORT ORDER ; } if ( valu... | static SortOrder readSortOrder ( ByteBuffer buffer , int position , JetFormat format ) { short value = buffer . getShort ( position ) ; byte version = _NUM ; if ( format . SIZE_SORT_ORDER == _NUM ) { version = buffer . get ( position + _NUM ) ; } if ( value == _NUM ) { return format . DEFAULT_SORT_ORDER ; } if ( value ... | 137 |
java-test-9819 | java | What does the code find ? | the node that represents a given function in a call graph | private static Function Block find Block ( final Callgraph callgraph , final Function function ) { for ( final Function Block callgraph Node : callgraph ) { if ( function == callgraph Node . get Function ( ) ) { return callgraph Node ; } } throw new Illegal State Exception ( STRING ) ; } | private static FunctionBlock findBlock ( final Callgraph callgraph , final Function function ) { for ( final FunctionBlock callgraphNode : callgraph ) { if ( function == callgraphNode . getFunction ( ) ) { return callgraphNode ; } } throw new IllegalStateException ( STRING ) ; } | 56 |
java-test-9820 | java | What does the node represent in a call graph ? | a given function | private static Function Block find Block ( final Callgraph callgraph , final Function function ) { for ( final Function Block callgraph Node : callgraph ) { if ( function == callgraph Node . get Function ( ) ) { return callgraph Node ; } } throw new Illegal State Exception ( STRING ) ; } | private static FunctionBlock findBlock ( final Callgraph callgraph , final Function function ) { for ( final FunctionBlock callgraphNode : callgraph ) { if ( function == callgraphNode . getFunction ( ) ) { return callgraphNode ; } } throw new IllegalStateException ( STRING ) ; } | 56 |
java-test-9821 | java | Where does the node represent a given function ? | in a call graph | private static Function Block find Block ( final Callgraph callgraph , final Function function ) { for ( final Function Block callgraph Node : callgraph ) { if ( function == callgraph Node . get Function ( ) ) { return callgraph Node ; } } throw new Illegal State Exception ( STRING ) ; } | private static FunctionBlock findBlock ( final Callgraph callgraph , final Function function ) { for ( final FunctionBlock callgraphNode : callgraph ) { if ( function == callgraphNode . getFunction ( ) ) { return callgraphNode ; } } throw new IllegalStateException ( STRING ) ; } | 56 |
java-test-9823 | java | What takes precedence if a " handle action " throws an exception when triggered by a source completion that also throws an exception if a " handle action " throws an exception when triggered by a source completion that also throws an exception ? | the action exception | public void test Handle source Failed Action Failed ( ) { for ( boolean create Incomplete : new boolean [ ] { BOOL , BOOL } ) for ( Execution Mode m : Execution Mode . values ( ) ) { final Atomic Integer a = new Atomic Integer ( NUM ) ; final CF Exception ex 1 = new CF Exception ( ) ; final CF Exception ex 2 = new CF E... | public void testHandle_sourceFailedActionFailed ( ) { for ( boolean createIncomplete : new boolean [ ] { _BOOL , _BOOL } ) for ( ExecutionMode m : ExecutionMode . values ( ) ) { final AtomicInteger a = new AtomicInteger ( _NUM ) ; final CFException ex1 = new CFException ( ) ; final CFException ex2 = new CFException ( )... | 175 |
java-test-9827 | java | What will this print ? | the bits of the cell | @ Override public String to String ( ) { String Builder s = new String Builder ( NUM ) ; final int number Of Leading Zeros = Long . number Of Leading Zeros ( term ) ; for ( int i = NUM ; i < number Of Leading Zeros ; i ++ ) { s . append ( STRING ) ; } if ( term != NUM ) s . append ( Long . to Binary String ( term ) ) ;... | @ Override public String toString ( ) { StringBuilder s = new StringBuilder ( _NUM ) ; final int numberOfLeadingZeros = Long . numberOfLeadingZeros ( term ) ; for ( int i = _NUM ; i < numberOfLeadingZeros ; i ++ ) { s . append ( STRING ) ; } if ( term != _NUM ) s . append ( Long . toBinaryString ( term ) ) ; return s .... | 92 |
java-test-9828 | java | What does the code remove before and after the expression ? | whitespaces and comments | private void trim White Spaces And Comments ( org . eclipse . che . ide . ext . java . jdt . internal . compiler . ast . Expression expression ) { int start = expression . source Start ; int end = expression . source End ; int token ; int trim Left Position = expression . source Start ; int trim Right Position = expres... | private void trimWhiteSpacesAndComments ( org . eclipse . che . ide . ext . java . jdt . internal . compiler . ast . Expression expression ) { int start = expression . sourceStart ; int end = expression . sourceEnd ; int token ; int trimLeftPosition = expression . sourceStart ; int trimRightPosition = expression . sour... | 270 |
java-test-9829 | java | When does the code remove whitespaces and comments ? | before and after the expression | private void trim White Spaces And Comments ( org . eclipse . che . ide . ext . java . jdt . internal . compiler . ast . Expression expression ) { int start = expression . source Start ; int end = expression . source End ; int token ; int trim Left Position = expression . source Start ; int trim Right Position = expres... | private void trimWhiteSpacesAndComments ( org . eclipse . che . ide . ext . java . jdt . internal . compiler . ast . Expression expression ) { int start = expression . sourceStart ; int end = expression . sourceEnd ; int token ; int trimLeftPosition = expression . sourceStart ; int trimRightPosition = expression . sour... | 270 |
java-test-9830 | java | What does a task push ? | onto the task stack | public Task push Task ( String task Name , String description Format , Object ... args ) { clear Output ( ) ; String description = String . format ( description Format , args ) ; String indented = indent ( description + STRING ) ; out . print ( indented ) ; Task t = new Task ( task Name , description Format , args ) ; ... | public Task pushTask ( String taskName , String descriptionFormat , Object ... args ) { clearOutput ( ) ; String description = String . format ( descriptionFormat , args ) ; String indented = indent ( description + STRING ) ; out . print ( indented ) ; Task t = new Task ( taskName , descriptionFormat , args ) ; stack .... | 84 |
java-test-9831 | java | What does the code create ? | an identity string given a mac address | private String create Identity ( byte [ ] mac ) { String Builder sb = new String Builder ( STRING ) ; try { for ( int i = NUM ; i < mac . length ; i ++ ) { sb . append ( String . format ( STRING , mac [ i ] ) ) ; } } catch ( Null Pointer Exception ex ) { return null ; } return sb . to String ( ) ; } | private String createIdentity ( byte [ ] mac ) { StringBuilder sb = new StringBuilder ( STRING ) ; try { for ( int i = _NUM ; i < mac . length ; i ++ ) { sb . append ( String . format ( STRING , mac [ i ] ) ) ; } } catch ( NullPointerException ex ) { return null ; } return sb . toString ( ) ; } | 81 |
java-test-9832 | java | What will this return ? | the squared loss of the given points | public static double squared Loss ( double [ ] x , double [ ] y , double w 0 , double w 1 ) { double sum = NUM ; for ( int j = NUM ; j < x . length ; j ++ ) { sum += Math . pow ( ( y [ j ] - ( w 1 * x [ j ] + w 0 ) ) , NUM ) ; } return sum ; } | public static double squaredLoss ( double [ ] x , double [ ] y , double w_0 , double w_1 ) { double sum = _NUM ; for ( int j = _NUM ; j < x . length ; j ++ ) { sum += Math . pow ( ( y [ j ] - ( w_1 * x [ j ] + w_0 ) ) , _NUM ) ; } return sum ; } | 81 |
java-test-9833 | java | When does the code calculate wait duration ? | after failure attempt | public synchronized long exponential Wait ( ) { long max Delay Ret = min Delay + ( ( max Delay - min Delay ) / max Failure Count ) * current Failure Count ; return ( long ) ( random . next Float ( ) * max Delay Ret ) ; } | public synchronized long exponentialWait ( ) { long maxDelayRet = minDelay + ( ( maxDelay - minDelay ) / maxFailureCount ) * currentFailureCount ; return ( long ) ( random . nextFloat ( ) * maxDelayRet ) ; } | 52 |
java-test-9834 | java | What does this method not duplicate ? | selection listeners and property listeners | public Object clone ( ) throws Clone Not Supported Exception { Default Tree Selection Model clone = ( Default Tree Selection Model ) super . clone ( ) ; clone . change Support = null ; if ( selection != null ) { int sel Length = selection . length ; clone . selection = new Tree Path [ sel Length ] ; System . arraycopy ... | public Object clone ( ) throws CloneNotSupportedException { DefaultTreeSelectionModel clone = ( DefaultTreeSelectionModel ) super . clone ( ) ; clone . changeSupport = null ; if ( selection != null ) { int selLength = selection . length ; clone . selection = new TreePath [ selLength ] ; System . arraycopy ( selection ,... | 162 |
java-test-9835 | java | How does a clone of this object return ? | with the same selection | public Object clone ( ) throws Clone Not Supported Exception { Default Tree Selection Model clone = ( Default Tree Selection Model ) super . clone ( ) ; clone . change Support = null ; if ( selection != null ) { int sel Length = selection . length ; clone . selection = new Tree Path [ sel Length ] ; System . arraycopy ... | public Object clone ( ) throws CloneNotSupportedException { DefaultTreeSelectionModel clone = ( DefaultTreeSelectionModel ) super . clone ( ) ; clone . changeSupport = null ; if ( selection != null ) { int selLength = selection . length ; clone . selection = new TreePath [ selLength ] ; System . arraycopy ( selection ,... | 162 |
java-test-9836 | java | What does the code add to the configuration controller ? | a core command tag changer | public void add Core Command Tag Changer ( final Long equipment Id , final I Core Command Tag Changer command Tag Changer ) { List < I Core Command Tag Changer > changers = core Command Tag Changers . get ( equipment Id ) ; if ( changers == null ) { changers = new Array List < > ( ) ; core Command Tag Changers . put ( ... | public void addCoreCommandTagChanger ( final Long equipmentId , final ICoreCommandTagChanger commandTagChanger ) { List < ICoreCommandTagChanger > changers = coreCommandTagChangers . get ( equipmentId ) ; if ( changers == null ) { changers = new ArrayList < > ( ) ; coreCommandTagChangers . put ( equipmentId , changers ... | 86 |
java-test-9838 | java | How did the code walking speed change ? | according to health / exhaustion / fat | @ Subscribe Event public void walking Penalty ( Living Update Event event ) { if ( ! ( event . get Entity Living ( ) instanceof Entity Player ) ) return ; Entity Player player = ( Entity Player ) event . get Entity Living ( ) ; if ( ! Entity Player Ext . is Survival ( player ) ) return ; if ( ! ( player . get Food Stat... | @ SubscribeEvent public void walkingPenalty ( LivingUpdateEvent event ) { if ( ! ( event . getEntityLiving ( ) instanceof EntityPlayer ) ) return ; EntityPlayer player = ( EntityPlayer ) event . getEntityLiving ( ) ; if ( ! EntityPlayerExt . isSurvival ( player ) ) return ; if ( ! ( player . getFoodStats ( ) instanceof... | 126 |
java-test-9839 | java | What does the code open ? | the given stream and quality | public void open ( String stream , String quality ) { if ( stream != null ) { String url = STRING + stream ; if ( ! Helper . validate Channel ( stream ) ) { url = stream ; } Item existing Item = get Exisiting Item ( url , quality ) ; if ( existing Item != null ) { existing Item . start ( ) ; tabs . set Selected Compone... | public void open ( String stream , String quality ) { if ( stream != null ) { String url = STRING + stream ; if ( ! Helper . validateChannel ( stream ) ) { url = stream ; } Item existingItem = getExisitingItem ( url , quality ) ; if ( existingItem != null ) { existingItem . start ( ) ; tabs . setSelectedComponent ( exi... | 199 |
java-test-9840 | java | What iterates in eigenvalue information ? | matrix product | public double evaluate Iteration ( ) { double old Eigenvalue = eigenvalue ; transposed Eigenvector = transposed Eigenvector . secure Product ( matrix ) ; transposed Eigenvector = transposed Eigenvector . product ( NUM / transposed Eigenvector . components [ NUM ] ) ; eigenvector = matrix . secure Product ( eigenvector ... | public double evaluateIteration ( ) { double oldEigenvalue = eigenvalue ; transposedEigenvector = transposedEigenvector . secureProduct ( matrix ) ; transposedEigenvector = transposedEigenvector . product ( _NUM / transposedEigenvector . components [ _NUM ] ) ; eigenvector = matrix . secureProduct ( eigenvector ) ; eig... | 104 |
java-test-9841 | java | Where do matrix product iterate ? | in eigenvalue information | public double evaluate Iteration ( ) { double old Eigenvalue = eigenvalue ; transposed Eigenvector = transposed Eigenvector . secure Product ( matrix ) ; transposed Eigenvector = transposed Eigenvector . product ( NUM / transposed Eigenvector . components [ NUM ] ) ; eigenvector = matrix . secure Product ( eigenvector ... | public double evaluateIteration ( ) { double oldEigenvalue = eigenvalue ; transposedEigenvector = transposedEigenvector . secureProduct ( matrix ) ; transposedEigenvector = transposedEigenvector . product ( _NUM / transposedEigenvector . components [ _NUM ] ) ; eigenvector = matrix . secureProduct ( eigenvector ) ; eig... | 104 |
java-test-9844 | java | What starts the noxitem resources download ? | the code given a position associated to a noxitem | void load ( int position , boolean use Circular Transformation ) { if ( is Downloading ( position ) ) { return ; } Nox Item nox Item = nox Items . get ( position ) ; if ( ( nox Item . has Url ( ) && ! is Bitmap Ready ( position ) ) || nox Item . has Resource Id ( ) && ! is Drawable Ready ( position ) ) { loading [ posi... | void load ( int position , boolean useCircularTransformation ) { if ( isDownloading ( position ) ) { return ; } NoxItem noxItem = noxItems . get ( position ) ; if ( ( noxItem . hasUrl ( ) && ! isBitmapReady ( position ) ) || noxItem . hasResourceId ( ) && ! isDrawableReady ( position ) ) { loading [ position ] = _BOOL ... | 98 |
java-test-9845 | java | What will this load download only if wasn ' t previously downloaded or the download is not being performed ? | the resources associated to the noxitem | void load ( int position , boolean use Circular Transformation ) { if ( is Downloading ( position ) ) { return ; } Nox Item nox Item = nox Items . get ( position ) ; if ( ( nox Item . has Url ( ) && ! is Bitmap Ready ( position ) ) || nox Item . has Resource Id ( ) && ! is Drawable Ready ( position ) ) { loading [ posi... | void load ( int position , boolean useCircularTransformation ) { if ( isDownloading ( position ) ) { return ; } NoxItem noxItem = noxItems . get ( position ) ; if ( ( noxItem . hasUrl ( ) && ! isBitmapReady ( position ) ) || noxItem . hasResourceId ( ) && ! isDrawableReady ( position ) ) { loading [ position ] = _BOOL ... | 98 |
java-test-9846 | java | What will download the resources associated to the noxitem only if wasn ' t previously downloaded or the download is not being performed ? | this load | void load ( int position , boolean use Circular Transformation ) { if ( is Downloading ( position ) ) { return ; } Nox Item nox Item = nox Items . get ( position ) ; if ( ( nox Item . has Url ( ) && ! is Bitmap Ready ( position ) ) || nox Item . has Resource Id ( ) && ! is Drawable Ready ( position ) ) { loading [ posi... | void load ( int position , boolean useCircularTransformation ) { if ( isDownloading ( position ) ) { return ; } NoxItem noxItem = noxItems . get ( position ) ; if ( ( noxItem . hasUrl ( ) && ! isBitmapReady ( position ) ) || noxItem . hasResourceId ( ) && ! isDrawableReady ( position ) ) { loading [ position ] = _BOOL ... | 98 |
java-test-9847 | java | What did the code give ? | a position associated to a noxitem | void load ( int position , boolean use Circular Transformation ) { if ( is Downloading ( position ) ) { return ; } Nox Item nox Item = nox Items . get ( position ) ; if ( ( nox Item . has Url ( ) && ! is Bitmap Ready ( position ) ) || nox Item . has Resource Id ( ) && ! is Drawable Ready ( position ) ) { loading [ posi... | void load ( int position , boolean useCircularTransformation ) { if ( isDownloading ( position ) ) { return ; } NoxItem noxItem = noxItems . get ( position ) ; if ( ( noxItem . hasUrl ( ) && ! isBitmapReady ( position ) ) || noxItem . hasResourceId ( ) && ! isDrawableReady ( position ) ) { loading [ position ] = _BOOL ... | 98 |
java-test-9848 | java | What does the code given a position associated to a noxitem start ? | the noxitem resources download | void load ( int position , boolean use Circular Transformation ) { if ( is Downloading ( position ) ) { return ; } Nox Item nox Item = nox Items . get ( position ) ; if ( ( nox Item . has Url ( ) && ! is Bitmap Ready ( position ) ) || nox Item . has Resource Id ( ) && ! is Drawable Ready ( position ) ) { loading [ posi... | void load ( int position , boolean useCircularTransformation ) { if ( isDownloading ( position ) ) { return ; } NoxItem noxItem = noxItems . get ( position ) ; if ( ( noxItem . hasUrl ( ) && ! isBitmapReady ( position ) ) || noxItem . hasResourceId ( ) && ! isDrawableReady ( position ) ) { loading [ position ] = _BOOL ... | 98 |
java-test-9855 | java | What does the code load ? | the non - native call graph views of a module | public static I Filled List < I Callgraph View > load Callgraph Views ( final Abstract SQL Provider provider , final C Module module , final C Tag Manager view Tag Manager , final C Tag Manager node Tag Manager ) throws Couldnt Load Data Exception { return load Module Callgraphs ( provider , module , view Tag Manager ,... | public static IFilledList < ICallgraphView > loadCallgraphViews ( final AbstractSQLProvider provider , final CModule module , final CTagManager viewTagManager , final CTagManager nodeTagManager ) throws CouldntLoadDataException { return loadModuleCallgraphs ( provider , module , viewTagManager , nodeTagManager , ViewTy... | 72 |
java-test-9856 | java | When does a the pickup of the shipment schedule ? | right at the beginning of the tour | @ Deprecated public Builder schedule Pickup At Beginning ( Carrier Shipment shipment ) { assert Is Not Null ( shipment ) ; boolean was New = open Pickups . add ( shipment ) ; if ( ! was New ) { throw new Illegal State Exception ( STRING ) ; } Pickup pickup = create Pickup ( shipment ) ; tour Elements . add ( NUM , pick... | @ Deprecated public Builder schedulePickupAtBeginning ( CarrierShipment shipment ) { assertIsNotNull ( shipment ) ; boolean wasNew = openPickups . add ( shipment ) ; if ( ! wasNew ) { throw new IllegalStateException ( STRING ) ; } Pickup pickup = createPickup ( shipment ) ; tourElements . add ( _NUM , pickup ) ; return... | 74 |
java-test-9857 | java | What does the code add ? | a new spider scan result | public void add Scan Result ( String uri , String method , String flags , boolean skipped ) { Spider Scan Result result = new Spider Scan Result ( uri , method , flags , ! skipped ) ; synchronized ( scan Results ) { scan Results . add ( result ) ; try { fire Table Rows Inserted ( scan Results . size ( ) - NUM , scan Re... | public void addScanResult ( String uri , String method , String flags , boolean skipped ) { SpiderScanResult result = new SpiderScanResult ( uri , method , flags , ! skipped ) ; synchronized ( scanResults ) { scanResults . add ( result ) ; try { fireTableRowsInserted ( scanResults . size ( ) - _NUM , scanResults . size... | 93 |
java-test-9859 | java | When does loader try to find in the hashtable whether there is a value for that namespace ? | when resolving an entity | public static XML Input Source resolve Document ( XSD Description desc , Hashtable location Pairs , XML Entity Resolver entity Resolver ) throws IO Exception { String loc = null ; if ( desc . get Context Type ( ) == XSD Description . CONTEXT IMPORT || desc . from Instance ( ) ) { String namespace = desc . get Target Na... | public static XMLInputSource resolveDocument ( XSDDescription desc , Hashtable locationPairs , XMLEntityResolver entityResolver ) throws IOException { String loc = null ; if ( desc . getContextType ( ) == XSDDescription . CONTEXT_IMPORT || desc . fromInstance ( ) ) { String namespace = desc . getTargetNamespace ( ) ; S... | 215 |
java-test-9860 | java | What is loader find in the hashtable ? | whether there is a value for that namespace | public static XML Input Source resolve Document ( XSD Description desc , Hashtable location Pairs , XML Entity Resolver entity Resolver ) throws IO Exception { String loc = null ; if ( desc . get Context Type ( ) == XSD Description . CONTEXT IMPORT || desc . from Instance ( ) ) { String namespace = desc . get Target Na... | public static XMLInputSource resolveDocument ( XSDDescription desc , Hashtable locationPairs , XMLEntityResolver entityResolver ) throws IOException { String loc = null ; if ( desc . getContextType ( ) == XSDDescription . CONTEXT_IMPORT || desc . fromInstance ( ) ) { String namespace = desc . getTargetNamespace ( ) ; S... | 215 |
java-test-9861 | java | What does this method resolve ? | location of the given schema | public static XML Input Source resolve Document ( XSD Description desc , Hashtable location Pairs , XML Entity Resolver entity Resolver ) throws IO Exception { String loc = null ; if ( desc . get Context Type ( ) == XSD Description . CONTEXT IMPORT || desc . from Instance ( ) ) { String namespace = desc . get Target Na... | public static XMLInputSource resolveDocument ( XSDDescription desc , Hashtable locationPairs , XMLEntityResolver entityResolver ) throws IOException { String loc = null ; if ( desc . getContextType ( ) == XSDDescription . CONTEXT_IMPORT || desc . fromInstance ( ) ) { String namespace = desc . getTargetNamespace ( ) ; S... | 215 |
java-test-9862 | java | What does loader try when resolving an entity when resolving an entity ? | to find in the hashtable whether there is a value for that namespace | public static XML Input Source resolve Document ( XSD Description desc , Hashtable location Pairs , XML Entity Resolver entity Resolver ) throws IO Exception { String loc = null ; if ( desc . get Context Type ( ) == XSD Description . CONTEXT IMPORT || desc . from Instance ( ) ) { String namespace = desc . get Target Na... | public static XMLInputSource resolveDocument ( XSDDescription desc , Hashtable locationPairs , XMLEntityResolver entityResolver ) throws IOException { String loc = null ; if ( desc . getContextType ( ) == XSDDescription . CONTEXT_IMPORT || desc . fromInstance ( ) ) { String namespace = desc . getTargetNamespace ( ) ; S... | 215 |
java-test-9863 | java | What does this method try ? | to resolve location of the given schema | public static XML Input Source resolve Document ( XSD Description desc , Hashtable location Pairs , XML Entity Resolver entity Resolver ) throws IO Exception { String loc = null ; if ( desc . get Context Type ( ) == XSD Description . CONTEXT IMPORT || desc . from Instance ( ) ) { String namespace = desc . get Target Na... | public static XMLInputSource resolveDocument ( XSDDescription desc , Hashtable locationPairs , XMLEntityResolver entityResolver ) throws IOException { String loc = null ; if ( desc . getContextType ( ) == XSDDescription . CONTEXT_IMPORT || desc . fromInstance ( ) ) { String namespace = desc . getTargetNamespace ( ) ; S... | 215 |
java-test-9867 | java | What did the code add to a map stripping training list separator ? | key - value | private void add Tag To Map ( Map < String , String > map , String key , String value ) { if ( autocomplete Preset Item != null && autocomplete Preset Item . get Key Type ( key ) == Preset Key Type . MULTISELECT ) { if ( value . ends With ( String . value Of ( autocomplete Preset Item . get Delimiter ( key ) ) ) ) { va... | private void addTagToMap ( Map < String , String > map , String key , String value ) { if ( autocompletePresetItem != null && autocompletePresetItem . getKeyType ( key ) == PresetKeyType . MULTISELECT ) { if ( value . endsWith ( String . valueOf ( autocompletePresetItem . getDelimiter ( key ) ) ) ) { value = value . su... | 102 |
java-test-9868 | java | What do a map strip ? | training list separator | private void add Tag To Map ( Map < String , String > map , String key , String value ) { if ( autocomplete Preset Item != null && autocomplete Preset Item . get Key Type ( key ) == Preset Key Type . MULTISELECT ) { if ( value . ends With ( String . value Of ( autocomplete Preset Item . get Delimiter ( key ) ) ) ) { va... | private void addTagToMap ( Map < String , String > map , String key , String value ) { if ( autocompletePresetItem != null && autocompletePresetItem . getKeyType ( key ) == PresetKeyType . MULTISELECT ) { if ( value . endsWith ( String . valueOf ( autocompletePresetItem . getDelimiter ( key ) ) ) ) { value = value . su... | 102 |
java-test-9870 | java | What does the given collection contain ? | exactly all of the exptectedentries | private < T > void assert Contains ( final T [ ] expected Entries , final Collection < T > collection ) { assert Equals ( expected Entries . length , collection . size ( ) ) ; for ( T t : expected Entries ) { assert True ( collection . contains ( t ) ) ; } } | private < T > void assertContains ( final T [ ] expectedEntries , final Collection < T > collection ) { assertEquals ( expectedEntries . length , collection . size ( ) ) ; for ( T t : expectedEntries ) { assertTrue ( collection . contains ( t ) ) ; } } | 60 |
java-test-9874 | java | What does the code make ? | something like a random " database " fixed point double , tostring ' s it , and checks parsing | public void test Doubles Larger Than Life ( ) throws Exception { int iters = at Least ( NUM ) ; for ( int i = NUM ; i < iters ; i ++ ) { Big Integer unscaled = Test Util . next Big Integer ( random ( ) , NUM ) ; int scale = Test Util . next Int ( random ( ) , - NUM , NUM ) ; int precision = Test Util . next Int ( rando... | public void testDoublesLargerThanLife ( ) throws Exception { int iters = atLeast ( _NUM ) ; for ( int i = _NUM ; i < iters ; i ++ ) { BigInteger unscaled = TestUtil . nextBigInteger ( random ( ) , _NUM ) ; int scale = TestUtil . nextInt ( random ( ) , - _NUM , _NUM ) ; int precision = TestUtil . nextInt ( random ( ) , ... | 152 |
java-test-9875 | java | What does we check for now ? | up to 100 digits | public void test Doubles Larger Than Life ( ) throws Exception { int iters = at Least ( NUM ) ; for ( int i = NUM ; i < iters ; i ++ ) { Big Integer unscaled = Test Util . next Big Integer ( random ( ) , NUM ) ; int scale = Test Util . next Int ( random ( ) , - NUM , NUM ) ; int precision = Test Util . next Int ( rando... | public void testDoublesLargerThanLife ( ) throws Exception { int iters = atLeast ( _NUM ) ; for ( int i = _NUM ; i < iters ; i ++ ) { BigInteger unscaled = TestUtil . nextBigInteger ( random ( ) , _NUM ) ; int scale = TestUtil . nextInt ( random ( ) , - _NUM , _NUM ) ; int precision = TestUtil . nextInt ( random ( ) , ... | 152 |
java-test-9876 | java | How does strings concatenate ? | using a separator | public static String join ( Char Sequence separator , Iterable < String > strings ) { String Builder sb = new String Builder ( ) ; boolean first = BOOL ; for ( String s : strings ) { if ( first ) { first = BOOL ; } else { sb . append ( separator ) ; } sb . append ( s ) ; } return sb . to String ( ) ; } | public static String join ( CharSequence separator , Iterable < String > strings ) { StringBuilder sb = new StringBuilder ( ) ; boolean first = _BOOL ; for ( String s : strings ) { if ( first ) { first = _BOOL ; } else { sb . append ( separator ) ; } sb . append ( s ) ; } return sb . toString ( ) ; } | 76 |
java-test-9877 | java | For what purpose is block not allocated to a warrant ? | for use by circuitbuilder only | public String allocate ( String path Name ) { if ( log . is Debug Enabled ( ) ) { log . debug ( STRING + path Name + STRING + get System Name ( ) + STRING + get State ( ) ) ; } if ( path Name == null ) { log . error ( STRING + get Display Name ( ) + STRING ) ; return null ; } else if ( warrant != null ) { return Bundle... | public String allocate ( String pathName ) { if ( log . isDebugEnabled ( ) ) { log . debug ( STRING + pathName + STRING + getSystemName ( ) + STRING + getState ( ) ) ; } if ( pathName == null ) { log . error ( STRING + getDisplayName ( ) + STRING ) ; return null ; } else if ( _warrant != null ) { return Bundle . getMes... | 155 |
java-test-9878 | java | For what purpose do command run ? | to get dump file | public boolean runtest ( ) { clean Temp ( ) ; Command Line command = adb Command ( STRING , STRING , STRING , STRING , STRING , STRING ) ; String output = execute Command Quietly ( command ) ; log . debug ( STRING , output ) ; try { Thread . sleep ( NUM ) ; } catch ( Interrupted Exception ie ) { throw new Runtime Excep... | public boolean runtest ( ) { cleanTemp ( ) ; CommandLine command = adbCommand ( STRING , STRING , STRING , STRING , STRING , STRING ) ; String output = executeCommandQuietly ( command ) ; log . debug ( STRING , output ) ; try { Thread . sleep ( _NUM ) ; } catch ( InterruptedException ie ) { throw new RuntimeException (... | 85 |
java-test-9879 | java | What can call this method internally internally for ensuring capacity ? | synchronized methods in this class | private void ensure Capacity Helper ( int min Capacity ) { int old Capacity = element Data . length ; if ( min Capacity > old Capacity ) { Object [ ] old Data = element Data ; int new Capacity = ( capacity Increment > NUM ) ? ( old Capacity + capacity Increment ) : ( old Capacity * NUM ) ; if ( new Capacity < min Capac... | private void ensureCapacityHelper ( int minCapacity ) { int oldCapacity = elementData . length ; if ( minCapacity > oldCapacity ) { Object [ ] oldData = elementData ; int newCapacity = ( capacityIncrement > _NUM ) ? ( oldCapacity + capacityIncrement ) : ( oldCapacity * _NUM ) ; if ( newCapacity < minCapacity ) { newCap... | 110 |
java-test-9880 | java | What does this implement ? | the unsynchronized semantics of ensurecapacity | private void ensure Capacity Helper ( int min Capacity ) { int old Capacity = element Data . length ; if ( min Capacity > old Capacity ) { Object [ ] old Data = element Data ; int new Capacity = ( capacity Increment > NUM ) ? ( old Capacity + capacity Increment ) : ( old Capacity * NUM ) ; if ( new Capacity < min Capac... | private void ensureCapacityHelper ( int minCapacity ) { int oldCapacity = elementData . length ; if ( minCapacity > oldCapacity ) { Object [ ] oldData = elementData ; int newCapacity = ( capacityIncrement > _NUM ) ? ( oldCapacity + capacityIncrement ) : ( oldCapacity * _NUM ) ; if ( newCapacity < minCapacity ) { newCap... | 110 |
java-test-9881 | java | For what purpose can synchronized methods in this class call this method internally internally ? | for ensuring capacity | private void ensure Capacity Helper ( int min Capacity ) { int old Capacity = element Data . length ; if ( min Capacity > old Capacity ) { Object [ ] old Data = element Data ; int new Capacity = ( capacity Increment > NUM ) ? ( old Capacity + capacity Increment ) : ( old Capacity * NUM ) ; if ( new Capacity < min Capac... | private void ensureCapacityHelper ( int minCapacity ) { int oldCapacity = elementData . length ; if ( minCapacity > oldCapacity ) { Object [ ] oldData = elementData ; int newCapacity = ( capacityIncrement > _NUM ) ? ( oldCapacity + capacityIncrement ) : ( oldCapacity * _NUM ) ; if ( newCapacity < minCapacity ) { newCap... | 110 |
java-test-9883 | java | What must the caller have ? | discoverypermission for each group | public void add Groups ( String [ ] new Groups ) throws IO Exception { test Array For Null Element ( new Groups ) ; check Groups ( new Groups ) ; synchronized ( registrars ) { if ( terminated ) throw new Illegal State Exception ( STRING ) ; if ( groups == null ) throw new Unsupported Operation Exception ( STRING ) ; Co... | public void addGroups ( String [ ] newGroups ) throws IOException { testArrayForNullElement ( newGroups ) ; checkGroups ( newGroups ) ; synchronized ( registrars ) { if ( terminated ) throw new IllegalStateException ( STRING ) ; if ( groups == null ) throw new UnsupportedOperationException ( STRING ) ; Collection req =... | 139 |
java-test-9884 | java | What have the code add to the set to be discovered ? | a set of groups | public void add Groups ( String [ ] new Groups ) throws IO Exception { test Array For Null Element ( new Groups ) ; check Groups ( new Groups ) ; synchronized ( registrars ) { if ( terminated ) throw new Illegal State Exception ( STRING ) ; if ( groups == null ) throw new Unsupported Operation Exception ( STRING ) ; Co... | public void addGroups ( String [ ] newGroups ) throws IOException { testArrayForNullElement ( newGroups ) ; checkGroups ( newGroups ) ; synchronized ( registrars ) { if ( terminated ) throw new IllegalStateException ( STRING ) ; if ( groups == null ) throw new UnsupportedOperationException ( STRING ) ; Collection req =... | 139 |
java-test-9885 | java | For what purpose have the code add a set of groups to the set ? | to be discovered | public void add Groups ( String [ ] new Groups ) throws IO Exception { test Array For Null Element ( new Groups ) ; check Groups ( new Groups ) ; synchronized ( registrars ) { if ( terminated ) throw new Illegal State Exception ( STRING ) ; if ( groups == null ) throw new Unsupported Operation Exception ( STRING ) ; Co... | public void addGroups ( String [ ] newGroups ) throws IOException { testArrayForNullElement ( newGroups ) ; checkGroups ( newGroups ) ; synchronized ( registrars ) { if ( terminated ) throw new IllegalStateException ( STRING ) ; if ( groups == null ) throw new UnsupportedOperationException ( STRING ) ; Collection req =... | 139 |
java-test-9891 | java | What does all storage files match ? | the expected s3 key prefix value | public void validate Storage Files ( Collection < String > storage File Paths , String s3 Key Prefix , Business Object Data Entity business Object Data Entity , String storage Name ) throws Illegal Argument Exception { for ( String storage File Path : storage File Paths ) { Assert . is True ( storage File Path . starts... | public void validateStorageFiles ( Collection < String > storageFilePaths , String s3KeyPrefix , BusinessObjectDataEntity businessObjectDataEntity , String storageName ) throws IllegalArgumentException { for ( String storageFilePath : storageFilePaths ) { Assert . isTrue ( storageFilePath . startsWith ( s3KeyPrefix ) ,... | 107 |
java-test-9892 | java | What match the expected s3 key prefix value ? | all storage files | public void validate Storage Files ( Collection < String > storage File Paths , String s3 Key Prefix , Business Object Data Entity business Object Data Entity , String storage Name ) throws Illegal Argument Exception { for ( String storage File Path : storage File Paths ) { Assert . is True ( storage File Path . starts... | public void validateStorageFiles ( Collection < String > storageFilePaths , String s3KeyPrefix , BusinessObjectDataEntity businessObjectDataEntity , String storageName ) throws IllegalArgumentException { for ( String storageFilePath : storageFilePaths ) { Assert . isTrue ( storageFilePath . startsWith ( s3KeyPrefix ) ,... | 107 |
java-test-9894 | java | What contains query ' fb ' , but not ' bf ' ? | name ' foobar ' | private boolean contains Chars In Order ( String name , String query ) { int i Name = NUM , i Query = NUM ; while ( i Name < name . length ( ) && i Query < query . length ( ) ) { if ( name . char At ( i Name ) == query . char At ( i Query ) ) { i Name ++ ; i Query ++ ; } else { i Name ++ ; } } return i Query == query .... | private boolean containsCharsInOrder ( String name , String query ) { int iName = _NUM , iQuery = _NUM ; while ( iName < name . length ( ) && iQuery < query . length ( ) ) { if ( name . charAt ( iName ) == query . charAt ( iQuery ) ) { iName ++ ; iQuery ++ ; } else { iName ++ ; } } return iQuery == query . length ( ) ;... | 95 |
java-test-9895 | java | What do name contain in order ? | all the characters of query | private boolean contains Chars In Order ( String name , String query ) { int i Name = NUM , i Query = NUM ; while ( i Name < name . length ( ) && i Query < query . length ( ) ) { if ( name . char At ( i Name ) == query . char At ( i Query ) ) { i Name ++ ; i Query ++ ; } else { i Name ++ ; } } return i Query == query .... | private boolean containsCharsInOrder ( String name , String query ) { int iName = _NUM , iQuery = _NUM ; while ( iName < name . length ( ) && iQuery < query . length ( ) ) { if ( name . charAt ( iName ) == query . charAt ( iQuery ) ) { iName ++ ; iQuery ++ ; } else { iName ++ ; } } return iQuery == query . length ( ) ;... | 95 |
java-test-9896 | java | What does name ' foobar ' contain ? | query ' fb ' , but not ' bf ' | private boolean contains Chars In Order ( String name , String query ) { int i Name = NUM , i Query = NUM ; while ( i Name < name . length ( ) && i Query < query . length ( ) ) { if ( name . char At ( i Name ) == query . char At ( i Query ) ) { i Name ++ ; i Query ++ ; } else { i Name ++ ; } } return i Query == query .... | private boolean containsCharsInOrder ( String name , String query ) { int iName = _NUM , iQuery = _NUM ; while ( iName < name . length ( ) && iQuery < query . length ( ) ) { if ( name . charAt ( iName ) == query . charAt ( iQuery ) ) { iName ++ ; iQuery ++ ; } else { iName ++ ; } } return iQuery == query . length ( ) ;... | 95 |
java-test-9897 | java | What does the code remove ? | all available plugins | public void remove All Plugins ( ) { Iterator < Abstract Plugin > iter = all Plugins . iterator ( ) ; while ( iter . has Next ( ) ) { Abstract Plugin plugin = ( Abstract Plugin ) iter . next ( ) ; plugin . remove Plugin Observer ( this ) ; active Plugins . remove ( plugin ) ; iter . remove ( ) ; } } | public void removeAllPlugins ( ) { Iterator < AbstractPlugin > iter = allPlugins . iterator ( ) ; while ( iter . hasNext ( ) ) { AbstractPlugin plugin = ( AbstractPlugin ) iter . next ( ) ; plugin . removePluginObserver ( this ) ; activePlugins . remove ( plugin ) ; iter . remove ( ) ; } } | 71 |
java-test-9898 | java | What does the code retrieve from the given start date ? | a page of mailbox dump requests | public Generic Feed retrieve Page Of Mailbox Dump Requests ( Date from Date ) throws Apps For Your Domain Exception , Malformed URL Exception , IO Exception , Service Exception { String url = BASE URL + STRING + domain ; if ( from Date != null ) { url += STRING + DATE FORMAT . format ( from Date ) ; } return get Feed (... | public GenericFeed retrievePageOfMailboxDumpRequests ( Date fromDate ) throws AppsForYourDomainException , MalformedURLException , IOException , ServiceException { String url = BASE_URL + STRING + domain ; if ( fromDate != null ) { url += STRING + DATE_FORMAT . format ( fromDate ) ; } return getFeed ( new URL ( url ) ,... | 80 |
java-test-9902 | java | What do the first and the last indexes of the child views need ? | to be notified of the change to the model | void calculate Update Indexes ( Document Event e ) { int pos = e . get Offset ( ) ; first Update Index = get View Index ( pos , Position . Bias . Forward ) ; if ( first Update Index == - NUM && e . get Type ( ) == Document Event . Event Type . REMOVE && pos >= get End Offset ( ) ) { first Update Index = get View Count ... | void calculateUpdateIndexes ( DocumentEvent e ) { int pos = e . getOffset ( ) ; firstUpdateIndex = getViewIndex ( pos , Position . Bias . Forward ) ; if ( firstUpdateIndex == - _NUM && e . getType ( ) == DocumentEvent . EventType . REMOVE && pos >= getEndOffset ( ) ) { firstUpdateIndex = getViewCount ( ) - _NUM ; } las... | 240 |
java-test-9903 | java | What does the code calculate ? | the first and the last indexes of the child views that need to be notified of the change to the model | void calculate Update Indexes ( Document Event e ) { int pos = e . get Offset ( ) ; first Update Index = get View Index ( pos , Position . Bias . Forward ) ; if ( first Update Index == - NUM && e . get Type ( ) == Document Event . Event Type . REMOVE && pos >= get End Offset ( ) ) { first Update Index = get View Count ... | void calculateUpdateIndexes ( DocumentEvent e ) { int pos = e . getOffset ( ) ; firstUpdateIndex = getViewIndex ( pos , Position . Bias . Forward ) ; if ( firstUpdateIndex == - _NUM && e . getType ( ) == DocumentEvent . EventType . REMOVE && pos >= getEndOffset ( ) ) { firstUpdateIndex = getViewCount ( ) - _NUM ; } las... | 240 |
java-test-9904 | java | What need to be notified of the change to the model ? | the first and the last indexes of the child views | void calculate Update Indexes ( Document Event e ) { int pos = e . get Offset ( ) ; first Update Index = get View Index ( pos , Position . Bias . Forward ) ; if ( first Update Index == - NUM && e . get Type ( ) == Document Event . Event Type . REMOVE && pos >= get End Offset ( ) ) { first Update Index = get View Count ... | void calculateUpdateIndexes ( DocumentEvent e ) { int pos = e . getOffset ( ) ; firstUpdateIndex = getViewIndex ( pos , Position . Bias . Forward ) ; if ( firstUpdateIndex == - _NUM && e . getType ( ) == DocumentEvent . EventType . REMOVE && pos >= getEndOffset ( ) ) { firstUpdateIndex = getViewCount ( ) - _NUM ; } las... | 240 |
java-test-9907 | java | What checks exception ? | getinstance ( string algorithm , string provider | public void test Get Instance ( ) throws Exception { try { Exemption Mechanism . get Instance ( ( String ) null , STRING ) ; fail ( STRING ) ; } catch ( No Such Provider Exception pe ) { } try { Exemption Mechanism . get Instance ( STRING , ( String ) null ) ; fail ( STRING ) ; } catch ( Illegal Argument Exception e ) ... | public void testGetInstance ( ) throws Exception { try { ExemptionMechanism . getInstance ( ( String ) null , STRING ) ; fail ( STRING ) ; } catch ( NoSuchProviderException pe ) { } try { ExemptionMechanism . getInstance ( STRING , ( String ) null ) ; fail ( STRING ) ; } catch ( IllegalArgumentException e ) { } } | 74 |
java-test-9908 | java | What performs on all objects that require it ? | creation - time injections | void inject All ( final Errors errors ) { for ( Injectable Reference < ? > reference : new Array List < > ( pending Injection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( Errors Exception e ) { errors . merge ( e . get Errors ( ) ) ; } } if ( ! pending Injection . is Empty ( ) ) { throw new Assertion... | void injectAll ( final Errors errors ) { for ( InjectableReference < ? > reference : new ArrayList < > ( pendingInjection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( ErrorsException e ) { errors . merge ( e . getErrors ( ) ) ; } } if ( ! pendingInjection . isEmpty ( ) ) { throw new AssertionError ( ... | 96 |
java-test-9909 | java | Where does creation - time injections perform ? | on all objects that require it | void inject All ( final Errors errors ) { for ( Injectable Reference < ? > reference : new Array List < > ( pending Injection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( Errors Exception e ) { errors . merge ( e . get Errors ( ) ) ; } } if ( ! pending Injection . is Empty ( ) ) { throw new Assertion... | void injectAll ( final Errors errors ) { for ( InjectableReference < ? > reference : new ArrayList < > ( pendingInjection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( ErrorsException e ) { errors . merge ( e . getErrors ( ) ) ; } } if ( ! pendingInjection . isEmpty ( ) ) { throw new AssertionError ( ... | 96 |
java-test-9910 | java | When is ordering of injection arbitrary if the two instances are codependent ( directly or transitively ) ? | whenever fulfilling an injection depends on another object that requires injection | void inject All ( final Errors errors ) { for ( Injectable Reference < ? > reference : new Array List < > ( pending Injection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( Errors Exception e ) { errors . merge ( e . get Errors ( ) ) ; } } if ( ! pending Injection . is Empty ( ) ) { throw new Assertion... | void injectAll ( final Errors errors ) { for ( InjectableReference < ? > reference : new ArrayList < > ( pendingInjection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( ErrorsException e ) { errors . merge ( e . getErrors ( ) ) ; } } if ( ! pendingInjection . isEmpty ( ) ) { throw new AssertionError ( ... | 96 |
java-test-9911 | java | How are the two instances are codependent ? | directly or transitively | void inject All ( final Errors errors ) { for ( Injectable Reference < ? > reference : new Array List < > ( pending Injection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( Errors Exception e ) { errors . merge ( e . get Errors ( ) ) ; } } if ( ! pending Injection . is Empty ( ) ) { throw new Assertion... | void injectAll ( final Errors errors ) { for ( InjectableReference < ? > reference : new ArrayList < > ( pendingInjection . values ( ) ) ) { try { reference . get ( errors ) ; } catch ( ErrorsException e ) { errors . merge ( e . getErrors ( ) ) ; } } if ( ! pendingInjection . isEmpty ( ) ) { throw new AssertionError ( ... | 96 |
java-test-9914 | java | What does the code unregister ? | any broadcastreceivers | public void close ( ) { while ( ! m Receivers . is Empty ( ) ) { m Context . unregister Receiver ( m Receivers . remove ( NUM ) ) ; } if ( m Output Writer != null ) { try { m Output Writer . close ( ) ; } catch ( IO Exception e ) { Log . w ( m Tag , STRING , e ) ; } } } | public void close ( ) { while ( ! mReceivers . isEmpty ( ) ) { mContext . unregisterReceiver ( mReceivers . remove ( _NUM ) ) ; } if ( mOutputWriter != null ) { try { mOutputWriter . close ( ) ; } catch ( IOException e ) { Log . w ( mTag , STRING , e ) ; } } } | 76 |
java-test-9915 | java | What does the code close ? | the utility instance | public void close ( ) { while ( ! m Receivers . is Empty ( ) ) { m Context . unregister Receiver ( m Receivers . remove ( NUM ) ) ; } if ( m Output Writer != null ) { try { m Output Writer . close ( ) ; } catch ( IO Exception e ) { Log . w ( m Tag , STRING , e ) ; } } } | public void close ( ) { while ( ! mReceivers . isEmpty ( ) ) { mContext . unregisterReceiver ( mReceivers . remove ( _NUM ) ) ; } if ( mOutputWriter != null ) { try { mOutputWriter . close ( ) ; } catch ( IOException e ) { Log . w ( mTag , STRING , e ) ; } } } | 76 |
java-test-9916 | java | What does the code remove ? | the 1st occurrence of the argument ( core mutation method ) | public boolean remove Arg ( final B Op arg ) { if ( arg == null ) throw new Illegal Argument Exception ( ) ; if ( arg == this ) throw new Illegal Argument Exception ( ) ; if ( args . remove ( arg ) ) { mutation ( ) ; return BOOL ; } return BOOL ; } | public boolean removeArg ( final BOp arg ) { if ( arg == null ) throw new IllegalArgumentException ( ) ; if ( arg == this ) throw new IllegalArgumentException ( ) ; if ( args . remove ( arg ) ) { mutation ( ) ; return _BOOL ; } return _BOOL ; } | 61 |
java-test-9917 | java | What provides the necessary credentials ? | a corresponding " server " configuration in the global settings | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9918 | java | What does this expect ? | that the pull request trigger is configured properly for this project and that it specifies a github project which has a corresponding " server " configuration in the global settings ( which provides the necessary credentials ) | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9919 | java | What did it specify ? | a github project which has a corresponding " server " configuration in the global settings ( which provides the necessary credentials ) | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9920 | java | What has a corresponding " server " configuration in the global settings ( which provides the necessary credentials ) ? | a github project | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9921 | java | What does a github project have ? | a corresponding " server " configuration in the global settings ( which provides the necessary credentials ) | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9922 | java | What does a corresponding " server " configuration in the global settings provide ? | the necessary credentials | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9923 | java | What does the code look ? | the github repository associated with this build | private GH Repository resolve Repository ( ) throws IO Exception { try { Git Hub PR Trigger trigger = gh PR Trigger From Run ( run ) ; if ( trigger != null ) { return trigger . get Remote Repository ( ) ; } else { throw new Abort Exception ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | private GHRepository resolveRepository ( ) throws IOException { try { GitHubPRTrigger trigger = ghPRTriggerFromRun ( run ) ; if ( trigger != null ) { return trigger . getRemoteRepository ( ) ; } else { throw new AbortException ( STRING ) ; } } catch ( Exception e ) { log . error ( STRING ) ; throw e ; } } | 75 |
java-test-9930 | java | What should pass a copy this method ? | situations where this would be undesirable | public static void rand Shuffle K ( Array List < Integer > inds , int k , Random rand ) { for ( int i = NUM ; i < k ; i ++ ) { Collections . swap ( inds , i , rand . next Int ( inds . size ( ) ) ) ; } } | public static void randShuffleK ( ArrayList < Integer > inds , int k , Random rand ) { for ( int i = _NUM ; i < k ; i ++ ) { Collections . swap ( inds , i , rand . nextInt ( inds . size ( ) ) ) ; } } | 59 |
java-test-9931 | java | What shuffles in a list ? | k integers | public static void rand Shuffle K ( Array List < Integer > inds , int k , Random rand ) { for ( int i = NUM ; i < k ; i ++ ) { Collections . swap ( inds , i , rand . next Int ( inds . size ( ) ) ) ; } } | public static void randShuffleK ( ArrayList < Integer > inds , int k , Random rand ) { for ( int i = _NUM ; i < k ; i ++ ) { Collections . swap ( inds , i , rand . nextInt ( inds . size ( ) ) ) ; } } | 59 |
java-test-9932 | java | What will this method alter ? | the list passed to it | public static void rand Shuffle K ( Array List < Integer > inds , int k , Random rand ) { for ( int i = NUM ; i < k ; i ++ ) { Collections . swap ( inds , i , rand . next Int ( inds . size ( ) ) ) ; } } | public static void randShuffleK ( ArrayList < Integer > inds , int k , Random rand ) { for ( int i = _NUM ; i < k ; i ++ ) { Collections . swap ( inds , i , rand . nextInt ( inds . size ( ) ) ) ; } } | 59 |
java-test-9934 | java | What does the code draw ? | the background annotations | private void draw ( final Execution Unit process , final Graphics 2 D g2 , final Process Renderer Model renderer Model , final boolean printing ) { Process Background Image image = renderer Model . get Background Image ( process ) ; if ( image != null ) { Graphics 2 D g2 D = ( Graphics 2 D ) g2 . create ( ) ; int x = i... | private void draw ( final ExecutionUnit process , final Graphics2D g2 , final ProcessRendererModel rendererModel , final boolean printing ) { ProcessBackgroundImage image = rendererModel . getBackgroundImage ( process ) ; if ( image != null ) { Graphics2D g2D = ( Graphics2D ) g2 . create ( ) ; int x = image . getX ( ) ... | 308 |
java-test-9935 | java | What does the code create ? | a new validator , which allows to validate texts to ensure , that they only contain letters | public Letter Validator ( @ Non Null final Char Sequence error Message , @ Non Null final Case case Sensitivity , final boolean allow Spaces , @ Non Null final char ... allowed Characters ) { super ( error Message ) ; set Case Sensitivity ( case Sensitivity ) ; allow Spaces ( allow Spaces ) ; set Allowed Characters ( a... | public LetterValidator ( @ NonNull final CharSequence errorMessage , @ NonNull final Case caseSensitivity , final boolean allowSpaces , @ NonNull final char ... allowedCharacters ) { super ( errorMessage ) ; setCaseSensitivity ( caseSensitivity ) ; allowSpaces ( allowSpaces ) ; setAllowedCharacters ( allowedCharacters ... | 66 |
java-test-9936 | java | For what purpose does which validate texts ? | to ensure , that they only contain letters | public Letter Validator ( @ Non Null final Char Sequence error Message , @ Non Null final Case case Sensitivity , final boolean allow Spaces , @ Non Null final char ... allowed Characters ) { super ( error Message ) ; set Case Sensitivity ( case Sensitivity ) ; allow Spaces ( allow Spaces ) ; set Allowed Characters ( a... | public LetterValidator ( @ NonNull final CharSequence errorMessage , @ NonNull final Case caseSensitivity , final boolean allowSpaces , @ NonNull final char ... allowedCharacters ) { super ( errorMessage ) ; setCaseSensitivity ( caseSensitivity ) ; allowSpaces ( allowSpaces ) ; setAllowedCharacters ( allowedCharacters ... | 66 |
java-test-9937 | java | What does a new validator allow ? | to validate texts to ensure , that they only contain letters | public Letter Validator ( @ Non Null final Char Sequence error Message , @ Non Null final Case case Sensitivity , final boolean allow Spaces , @ Non Null final char ... allowed Characters ) { super ( error Message ) ; set Case Sensitivity ( case Sensitivity ) ; allow Spaces ( allow Spaces ) ; set Allowed Characters ( a... | public LetterValidator ( @ NonNull final CharSequence errorMessage , @ NonNull final Case caseSensitivity , final boolean allowSpaces , @ NonNull final char ... allowedCharacters ) { super ( errorMessage ) ; setCaseSensitivity ( caseSensitivity ) ; allowSpaces ( allowSpaces ) ; setAllowedCharacters ( allowedCharacters ... | 66 |
java-test-9938 | java | What do you want ? | to read / write data | @ Main Thread public final void register ( Storage Access Listener storage Access Listener ) { if ( CHECK THREADS ) { Ui Thread Context . assert Ui Thread ( ) ; } if ( listeners . contains ( storage Access Listener ) ) { throw new Storage Access Exception ( STRING ) ; } listeners . add ( storage Access Listener ) ; } | @ MainThread public final void register ( StorageAccessListener storageAccessListener ) { if ( CHECK_THREADS ) { UiThreadContext . assertUiThread ( ) ; } if ( listeners . contains ( storageAccessListener ) ) { throw new StorageAccessException ( STRING ) ; } listeners . add ( storageAccessListener ) ; } | 65 |
java-test-9939 | java | What ll you need if you want to read / write data ? | to implement this to know when file access is ready | @ Main Thread public final void register ( Storage Access Listener storage Access Listener ) { if ( CHECK THREADS ) { Ui Thread Context . assert Ui Thread ( ) ; } if ( listeners . contains ( storage Access Listener ) ) { throw new Storage Access Exception ( STRING ) ; } listeners . add ( storage Access Listener ) ; } | @ MainThread public final void register ( StorageAccessListener storageAccessListener ) { if ( CHECK_THREADS ) { UiThreadContext . assertUiThread ( ) ; } if ( listeners . contains ( storageAccessListener ) ) { throw new StorageAccessException ( STRING ) ; } listeners . add ( storageAccessListener ) ; } | 65 |
java-test-9940 | java | What does the code create ? | a synchronization sample with a given time offset | public static List < Time Synchronization Sample > create Random Tolerable Samples With Different Key Pairs Around Mean ( final int count , final long mean ) { final Secure Random random = new Secure Random ( ) ; final List < Time Synchronization Sample > samples = new Array List < > ( ) ; if ( count % NUM == NUM ) { s... | public static List < TimeSynchronizationSample > createRandomTolerableSamplesWithDifferentKeyPairsAroundMean ( final int count , final long mean ) { final SecureRandom random = new SecureRandom ( ) ; final List < TimeSynchronizationSample > samples = new ArrayList < > ( ) ; if ( count % _NUM == _NUM ) { samples . add (... | 170 |
java-test-9941 | java | What does the code restore ? | the opengl state | public void end Drawing ( GL 10 gl ) { gl . gl Disable ( GL 10 . GL ALPHA TEST ) ; gl . gl Matrix Mode ( GL 10 . GL PROJECTION ) ; gl . gl Pop Matrix ( ) ; gl . gl Matrix Mode ( GL 10 . GL MODELVIEW ) ; gl . gl Pop Matrix ( ) ; gl . gl Disable ( GL 10 . GL TEXTURE 2D ) ; gl . gl Color 4 x ( Fixed Point . ONE , Fixed Po... | public void endDrawing ( GL10 gl ) { gl . glDisable ( GL10 . GL_ALPHA_TEST ) ; gl . glMatrixMode ( GL10 . GL_PROJECTION ) ; gl . glPopMatrix ( ) ; gl . glMatrixMode ( GL10 . GL_MODELVIEW ) ; gl . glPopMatrix ( ) ; gl . glDisable ( GL10 . GL_TEXTURE_2D ) ; gl . glColor4x ( FixedPoint . ONE , FixedPoint . ONE , FixedPoin... | 107 |
java-test-9944 | java | When will the input stream be read ? | only during submission | public void add Data ( String name , Input Stream data , long data Size , String mime Type ) { args . put ( name , data ) ; if ( ! filenames . contains Key ( name ) ) { filenames . put ( name , name ) ; } filesizes . put ( name , String . value Of ( data Size ) ) ; mime Types . put ( name , mime Type ) ; } | public void addData ( String name , InputStream data , long dataSize , String mimeType ) { args . put ( name , data ) ; if ( ! filenames . containsKey ( name ) ) { filenames . put ( name , name ) ; } filesizes . put ( name , String . valueOf ( dataSize ) ) ; mimeTypes . put ( name , mimeType ) ; } | 80 |
java-test-9945 | java | What represents a given criterium ? | a criterium tree node | public static C Criterium Tree Node find Node ( final C Criterium Tree Node node , final I Criterium criterium ) { if ( node . get Criterium ( ) == criterium ) { return node ; } for ( final C Criterium Tree Node child : node . get Children ( ) ) { final C Criterium Tree Node child Node = find Node ( child , criterium )... | public static CCriteriumTreeNode findNode ( final CCriteriumTreeNode node , final ICriterium criterium ) { if ( node . getCriterium ( ) == criterium ) { return node ; } for ( final CCriteriumTreeNode child : node . getChildren ( ) ) { final CCriteriumTreeNode childNode = findNode ( child , criterium ) ; if ( childNode ... | 89 |
java-test-9946 | java | What does a criterium tree node represent ? | a given criterium | public static C Criterium Tree Node find Node ( final C Criterium Tree Node node , final I Criterium criterium ) { if ( node . get Criterium ( ) == criterium ) { return node ; } for ( final C Criterium Tree Node child : node . get Children ( ) ) { final C Criterium Tree Node child Node = find Node ( child , criterium )... | public static CCriteriumTreeNode findNode ( final CCriteriumTreeNode node , final ICriterium criterium ) { if ( node . getCriterium ( ) == criterium ) { return node ; } for ( final CCriteriumTreeNode child : node . getChildren ( ) ) { final CCriteriumTreeNode childNode = findNode ( child , criterium ) ; if ( childNode ... | 89 |
java-test-9949 | java | What does a byte array contain ? | the gif encoded image | public static byte [ ] encode Gif ( Buffered Image image ) throws IO Exception { Byte Array Output Stream out = new Byte Array Output Stream ( ) ; if ( Debug . debugging ( STRING ) ) { Debug . output ( STRING + out ) ; } Acme . JPM . Encoders . Gif Encoder enc = new Acme . JPM . Encoders . Gif Encoder ( image , out ) ;... | public static byte [ ] encodeGif ( BufferedImage image ) throws IOException { ByteArrayOutputStream out = new ByteArrayOutputStream ( ) ; if ( Debug . debugging ( STRING ) ) { Debug . output ( STRING + out ) ; } Acme . JPM . Encoders . GifEncoder enc = new Acme . JPM . Encoders . GifEncoder ( image , out ) ; if ( Debug... | 127 |
java-test-9950 | java | What does the code create ? | a bloom filter of optimal size and hash functions for | public static Bloom Filter create Optimal Filter ( int n , double false Positive Probability , int tweak , Update Mode update ) { double ln 2 = Math . log ( NUM ) ; int mod = Math . max ( NUM , ( int ) Math . min ( ( - n * Math . log ( false Positive Probability ) / ( ln 2 * ln 2 ) ) / NUM , MAX FILTER SIZE ) ) ; int h... | public static BloomFilter createOptimalFilter ( int n , double falsePositiveProbability , int tweak , UpdateMode update ) { double ln2 = Math . log ( _NUM ) ; int mod = Math . max ( _NUM , ( int ) Math . min ( ( - n * Math . log ( falsePositiveProbability ) / ( ln2 * ln2 ) ) / _NUM , MAX_FILTER_SIZE ) ) ; int hashFunct... | 135 |
java-test-9951 | java | What do the given map have ? | the correct for each parameter | private static void enforce Parameter Types ( @ Not Null Template Metadata metadata , @ Not Null Map < String , Object > args ) { for ( Parameter p : metadata . get Parameters ( ) ) { Object o = args . get ( p . id ) ; if ( o == null ) { continue ; } switch ( p . type ) { case STRING : if ( ! ( o instanceof String ) ) ... | private static void enforceParameterTypes ( @ NotNull TemplateMetadata metadata , @ NotNull Map < String , Object > args ) { for ( Parameter p : metadata . getParameters ( ) ) { Object o = args . get ( p . id ) ; if ( o == null ) { continue ; } switch ( p . type ) { case STRING : if ( ! ( o instanceof String ) ) { args... | 159 |
java-test-9952 | java | What does this function create when more than one selector is needed for a subscriber ? | the selector string | private String multiple Selector String ( int current Number , int individual Total , int total Number ) { Number Sequencer tmp Sequencer = new Number Sequencer ( total Number ) ; tmp Sequencer . set Current Number ( current Number ) ; String Builder selector String = new String Builder ( ) ; for ( int i = NUM ; i < in... | private String multipleSelectorString ( int currentNumber , int individualTotal , int totalNumber ) { NumberSequencer tmpSequencer = new NumberSequencer ( totalNumber ) ; tmpSequencer . setCurrentNumber ( currentNumber ) ; StringBuilder selectorString = new StringBuilder ( ) ; for ( int i = _NUM ; i < individualTotal ;... | 116 |
java-test-9953 | java | How is more than one selector needed when ? | for a subscriber | private String multiple Selector String ( int current Number , int individual Total , int total Number ) { Number Sequencer tmp Sequencer = new Number Sequencer ( total Number ) ; tmp Sequencer . set Current Number ( current Number ) ; String Builder selector String = new String Builder ( ) ; for ( int i = NUM ; i < in... | private String multipleSelectorString ( int currentNumber , int individualTotal , int totalNumber ) { NumberSequencer tmpSequencer = new NumberSequencer ( totalNumber ) ; tmpSequencer . setCurrentNumber ( currentNumber ) ; StringBuilder selectorString = new StringBuilder ( ) ; for ( int i = _NUM ; i < individualTotal ;... | 116 |
java-test-9954 | java | When does this function create the selector string ? | when more than one selector is needed for a subscriber | private String multiple Selector String ( int current Number , int individual Total , int total Number ) { Number Sequencer tmp Sequencer = new Number Sequencer ( total Number ) ; tmp Sequencer . set Current Number ( current Number ) ; String Builder selector String = new String Builder ( ) ; for ( int i = NUM ; i < in... | private String multipleSelectorString ( int currentNumber , int individualTotal , int totalNumber ) { NumberSequencer tmpSequencer = new NumberSequencer ( totalNumber ) ; tmpSequencer . setCurrentNumber ( currentNumber ) ; StringBuilder selectorString = new StringBuilder ( ) ; for ( int i = _NUM ; i < individualTotal ;... | 116 |
java-test-9955 | java | What does the code draw ? | the content of the hex view | private void draw Hex View ( final Graphics g ) { final int standard Size = NUM * get Character Width ( g ) ; final int first X = ( - m first Column * m char Width ) + m padding Hex Left + m offset View Width ; int x = first X ; int y = m padding Top ; boolean even Column = BOOL ; byte [ ] data = null ; int bytes To Dr... | private void drawHexView ( final Graphics g ) { final int standardSize = _NUM * getCharacterWidth ( g ) ; final int firstX = ( - m_firstColumn * m_charWidth ) + m_paddingHexLeft + m_offsetViewWidth ; int x = firstX ; int y = m_paddingTop ; boolean evenColumn = _BOOL ; byte [ ] data = null ; int bytesToDraw ; if ( m_sta... | 752 |
java-test-9958 | java | What does the code create ? | a new view of the relation | protected T new Instance ( final Class < ? extends T > cls , final I Index Manager index Manager , final NT nt , final Properties properties ) { if ( cls == null ) throw new Illegal Argument Exception ( ) ; if ( index Manager == null ) throw new Illegal Argument Exception ( ) ; if ( nt == null ) throw new Illegal Argum... | protected T newInstance ( final Class < ? extends T > cls , final IIndexManager indexManager , final NT nt , final Properties properties ) { if ( cls == null ) throw new IllegalArgumentException ( ) ; if ( indexManager == null ) throw new IllegalArgumentException ( ) ; if ( nt == null ) throw new IllegalArgumentExcepti... | 243 |
java-test-9960 | java | What do we have ? | what tile | protected Map Tile find Covering ( int zoom , long i , long j ) { while ( zoom > NUM ) { zoom -- ; i = i / NUM ; j = j / NUM ; Map Tile candidate = find Tile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | protected MapTile findCovering ( int zoom , long i , long j ) { while ( zoom > _NUM ) { zoom -- ; i = i / _NUM ; j = j / _NUM ; MapTile candidate = findTile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | 79 |
java-test-9961 | java | What covers the " nearest " lower - zoom tile ? | a specific tile | protected Map Tile find Covering ( int zoom , long i , long j ) { while ( zoom > NUM ) { zoom -- ; i = i / NUM ; j = j / NUM ; Map Tile candidate = find Tile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | protected MapTile findCovering ( int zoom , long i , long j ) { while ( zoom > _NUM ) { zoom -- ; i = i / _NUM ; j = j / _NUM ; MapTile candidate = findTile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | 79 |
java-test-9962 | java | What does the code find ? | the " nearest " lower - zoom tile that covers a specific tile . this is used to find out what tile we have to show while a new tile is still loading | protected Map Tile find Covering ( int zoom , long i , long j ) { while ( zoom > NUM ) { zoom -- ; i = i / NUM ; j = j / NUM ; Map Tile candidate = find Tile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | protected MapTile findCovering ( int zoom , long i , long j ) { while ( zoom > _NUM ) { zoom -- ; i = i / _NUM ; j = j / _NUM ; MapTile candidate = findTile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | 79 |
java-test-9963 | java | What does a specific tile cover ? | the " nearest " lower - zoom tile | protected Map Tile find Covering ( int zoom , long i , long j ) { while ( zoom > NUM ) { zoom -- ; i = i / NUM ; j = j / NUM ; Map Tile candidate = find Tile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | protected MapTile findCovering ( int zoom , long i , long j ) { while ( zoom > _NUM ) { zoom -- ; i = i / _NUM ; j = j / _NUM ; MapTile candidate = findTile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | 79 |
java-test-9964 | java | What is this used ? | to find out what tile we have to show while a new tile is still loading | protected Map Tile find Covering ( int zoom , long i , long j ) { while ( zoom > NUM ) { zoom -- ; i = i / NUM ; j = j / NUM ; Map Tile candidate = find Tile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | protected MapTile findCovering ( int zoom , long i , long j ) { while ( zoom > _NUM ) { zoom -- ; i = i / _NUM ; j = j / _NUM ; MapTile candidate = findTile ( zoom , i , j ) ; if ( ( candidate != null ) && ( ! candidate . loading ( ) ) ) { return candidate ; } } return null ; } | 79 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.