idx
int64
0
69.7k
question
stringlengths
12
26.4k
target
stringlengths
15
2.3k
69,700
public ExampleSourceConfigurationWizard ( ConfigurationListener listener ) { super ( "Example Source Wizard" , listener ) ; dataViewPane . setVisible ( false ) ; addTitleStep ( ) ; addDataLoadingStep ( ) ; addColumnSeparatorStep ( ) ; addNameDefinitionStep ( ) ; addValueTypeDefinitionStep ( ) ; addAttributeTypeDefiniti...
Creates a new wizard.
69,701
int curveProgressToScreenY ( float p ) { if ( p < 0 || p > 1 ) return mStackVisibleRect . top + ( int ) ( p * mStackVisibleRect . height ( ) ) ; float pIndex = p * PrecisionSteps ; int pFloorIndex = ( int ) Math . floor ( pIndex ) ; int pCeilIndex = ( int ) Math . ceil ( pIndex ) ; float xFraction = 0 ; if ( pFloorInde...
Converts from the progress along the curve to a screen coordinate.
69,702
static Profile decode ( final String info ) { String [ ] params ; Profile profile ; String s ; params = info . split ( "\n" ) ; profile = new Profile ( ) ; if ( params . length > 0 ) { s = params [ 0 ] ; for ( final String host : OLD_SERVER_HOSTS ) { if ( s . equals ( host ) ) { s = NEW_SERVER_HOST ; break ; } } if ( s...
Decode a login profile from a string.
69,703
public static Map < String , Object > testSOAPService ( DispatchContext dctx , Map < String , ? > context ) { Delegator delegator = dctx . getDelegator ( ) ; Map < String , Object > response = ServiceUtil . returnSuccess ( ) ; List < GenericValue > testingNodes = new LinkedList < GenericValue > ( ) ; for ( int i = 0 ; ...
Generic Test SOAP Service
69,704
public void writeAll ( ResultSet rs , boolean includeColumnNames ) throws SQLException , IOException { if ( includeColumnNames ) { writeColumnNames ( rs ) ; } while ( rs . next ( ) ) { writeNext ( resultService . getColumnValues ( rs ) ) ; } }
Writes the entire ResultSet to a CSV file. The caller is responsible for closing the ResultSet.
69,705
public static void disableConnectionReuseIfNecessary ( ) { if ( Build . VERSION . SDK_INT < Build . VERSION_CODES . FROYO ) { System . setProperty ( "http.keepAlive" , "false" ) ; } }
Workaround for bug pre-Froyo, see here for more info: http://android-developers.blogspot.com/2011/09/androids-http-clients.html
69,706
private void updateRatingChoice ( ) { int current = m_chRating . getSelectedIndex ( ) ; m_chRating . removeAllItems ( ) ; FactionRecord fRec = ( FactionRecord ) m_chSubfaction . getSelectedItem ( ) ; if ( fRec == null ) { fRec = ( FactionRecord ) m_chFaction . getSelectedItem ( ) ; } ArrayList < String > ratingLevels =...
When faction or subfaction is changed, refresh ratings combo box with appropriate values for selected faction.
69,707
public static List < String > readLines ( File file ) throws IOException { return readLines ( file , Charset . defaultCharset ( ) ) ; }
Reads the contents of a file line by line to a List of Strings using the default encoding for the VM. The file is always closed.