@ SuppressWarnings ( "unchecked" ) public static ArrayList < JSONObject > createJSONDataElements  ( ) { ArrayList < JSONObject > dataElementsJSON = new ArrayList < > ( ) ; JSONObject jsonObj1 = new JSONObject ( ) ; jsonObj1 . put ( DATE , "2016-02-20T23:29:05.000Z" ) ; jsonObj1 . put ( QNAME , "a.b.c.com" ) ; jsonObj1 . put ( SRCIP , "55.55.55.55" ) ; jsonObj1 . put ( DSTIP , "1.2.3.6" ) ; jsonObj1 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj1 . put ( RCODE , 0 ) ; jsonObj1 . put ( IPS , new ArrayList < > ( Arrays . asList ( "10.20.30.40" , "10.20.30.60" ) ) ) ; dataElementsJSON . add ( jsonObj1 ) ; JSONObject jsonObj2 = new JSONObject ( ) ; jsonObj2 . put ( DATE , "2016-02-20T23:29:06.000Z" ) ; jsonObj2 . put ( QNAME , "d.e.com" ) ; jsonObj2 . put ( SRCIP , "127.128.129.130" ) ; jsonObj2 . put ( DSTIP , "1.2.3.4" ) ; jsonObj2 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj2 . put ( RCODE , 0 ) ; jsonObj2 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "5.6.7.8" ) ) ) ; dataElementsJSON . add ( jsonObj2 ) ; JSONObject jsonObj3 = new JSONObject ( ) ; jsonObj3 . put ( DATE , "2016-02-20T23:29:07.000Z" ) ; jsonObj3 . put ( QNAME , "d.e.com" ) ; jsonObj3 . put ( SRCIP , "131.132.133.134" ) ; jsonObj3 . put ( DSTIP , "9.10.11.12" ) ; jsonObj3 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj3 . put ( RCODE , 0 ) ; jsonObj3 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "13.14.15.16" ) ) ) ; dataElementsJSON . add ( jsonObj3 ) ; JSONObject jsonObj4 = new JSONObject ( ) ; jsonObj4 . put ( DATE , "2016-02-20T23:29:08.000Z" ) ; jsonObj4 . put ( QNAME , "d.e.com" ) ; jsonObj4 . put ( SRCIP , "135.136.137.138" ) ; jsonObj4 . put ( DSTIP , "17.18.19.20" ) ; jsonObj4 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj4 . put ( RCODE , 3 ) ; jsonObj4 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "21.22.23.24" ) ) ) ; dataElementsJSON . add ( jsonObj4 ) ; JSONObject jsonObj5 = new JSONObject ( ) ; jsonObj5 . put ( DATE , "2016-02-20T23:29:09.000Z" ) ; jsonObj5 . put ( QNAME , "d.e.com" ) ; jsonObj5 . put ( SRCIP , "139.140.141.142" ) ; jsonObj5 . put ( DSTIP , "25.26.27.28" ) ; jsonObj5 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj5 . put ( RCODE , 0 ) ; jsonObj5 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "5.6.7.8" ) ) ) ; dataElementsJSON . add ( jsonObj5 ) ; JSONObject jsonObj6 = new JSONObject ( ) ; jsonObj6 . put ( DATE , "2016-02-20T23:29:10.000Z" ) ; jsonObj6 . put ( QNAME , "d.e.com" ) ; jsonObj6 . put ( SRCIP , "143.144.145.146" ) ; jsonObj6 . put ( DSTIP , "33.34.35.36" ) ; jsonObj6 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj6 . put ( RCODE , 0 ) ; jsonObj6 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "5.6.7.8" ) ) ) ; dataElementsJSON . add ( jsonObj6 ) ; JSONObject jsonObj7 = new JSONObject ( ) ; jsonObj7 . put ( DATE , "2016-02-20T23:29:11.000Z" ) ; jsonObj7 . put ( QNAME , "something.else" ) ; jsonObj7 . put ( SRCIP , "1.1.1.1" ) ; jsonObj7 . put ( DSTIP , "2.2.2.2" ) ; jsonObj7 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj7 . put ( RCODE , 0 ) ; jsonObj7 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "3.3.3.3" ) ) ) ; dataElementsJSON . add ( jsonObj7 ) ; JSONObject jsonObj8 = new JSONObject ( ) ; jsonObj8 . put ( DATE , "2016-02-20T23:29:12.000Z" ) ; jsonObj8 . put ( QNAME , "something.else2" ) ; jsonObj8 . put ( SRCIP , "5.6.7.8" ) ; jsonObj8 . put ( DSTIP , "2.2.2.22" ) ; jsonObj8 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj8 . put ( RCODE , 0 ) ; jsonObj8 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "3.3.3.132" ) ) ) ; dataElementsJSON . add ( jsonObj8 ) ; JSONObject jsonObj9 = new JSONObject ( ) ; jsonObj9 . put ( DATE , "2016-02-20T23:29:13.000Z" ) ; jsonObj9 . put ( QNAME , "something.else.on.stoplist" ) ; jsonObj9 . put ( SRCIP , "55.55.55.55" ) ; jsonObj9 . put ( DSTIP , "2.2.2.232" ) ; jsonObj9 . put ( QTYPE , new ArrayList < > ( Collections . singletonList ( ( short ) 1 ) ) ) ; jsonObj9 . put ( RCODE , 0 ) ; jsonObj9 . put ( IPS , new ArrayList < > ( Collections . singletonList ( "3.3.3.132" ) ) ) ; dataElementsJSON . add ( jsonObj9 ) ; return dataElementsJSON ; }


public void incrementCurrentCount  ( boolean store ) throws GenericEntityException  { if ( store ) { info . set ( "recurrenceCount" , getCurrentCount ( ) + 1 ) ; info . store ( ) ; } }

Incrementa el recuento actual de esta recurrencia.


private void loadSettings  ( ) { Properties pIn = new Properties ( ) ; try { if ( ! ( new File ( "AutoSummENGGUI.properties" ) . exists ( ) ) ) return ; FileInputStream fsIn = new FileInputStream ( "AutoSummENGGUI.properties" ) ; pIn . loadFromXML ( fsIn ) ; fsIn . close ( ) ; } catch ( IOException ioe ) { ioe . printStackTrace ( System . err ) ; return ; } try { ModelsRootDirEdt . setText ( pIn . getProperty ( "ModelDir" , "./models" ) ) ; SummariesRootDirEdt . setText ( pIn . getProperty ( "SummaryDir" , "./summaries" ) ) ; OutputFileEdt . setText ( pIn . getProperty ( "OutputFile" , "./jinsect.table" ) ) ; ThreadCntEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "Threads" , "2" ) ) ) ; SilentChk . setSelected ( Boolean . valueOf ( pIn . getProperty ( "Silent" , Boolean . TRUE . toString ( ) ) ) ) ; ProgressChk . setSelected ( Boolean . valueOf ( pIn . getProperty ( "ShowProgress" , Boolean . TRUE . toString ( ) ) ) ) ; DoWordChk . setSelected ( Boolean . valueOf ( pIn . getProperty ( "DoWord" , Boolean . TRUE . toString ( ) ) ) ) ; DoWordChkStateChanged ( new ChangeEvent ( DoWordChk ) ) ; DoCharChk . setSelected ( Boolean . valueOf ( pIn . getProperty ( "DoChar" , Boolean . TRUE . toString ( ) ) ) ) ; DoCharChkStateChanged ( new ChangeEvent ( DoCharChk ) ) ; if ( pIn . getProperty ( "Use" , "Occurences" ) . equals ( "Occurences" ) ) OccurencesChk . setSelected ( true ) ; else DistrosChk . setSelected ( true ) ; CharMinEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "CharMin" , "3" ) ) ) ; CharMaxEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "CharMax" , "3" ) ) ) ; CharDistEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "CharDist" , "3" ) ) ) ; WordMinEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "WordMin" , "1" ) ) ) ; WordMaxEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "WordMax" , "2" ) ) ) ; WordDistEdt . setValue ( Integer . valueOf ( pIn . getProperty ( "WordDist" , "3" ) ) ) ; } catch ( Exception e ) { System . err . println ( "Could not load settings..." ) ; return ; } PerformanceTableModel tTmp = new PerformanceTableModel ( ) ; DetailedResultsTbl . setModel ( tTmp ) ; }

Cargar configuración de GUI desde el archivo.


private boolean tryStep  ( final double t0 , final double [ ] y0 , final double step , final int k , final double [ ] scale , final double [ ] [ ] f , final double [ ] yMiddle , final double [ ] yEnd ) throws MathIllegalArgumentException , MathIllegalStateException { final int n = sequence [ k ] ; final double subStep = step / n ; final double subStep2 = 2 * subStep ; double t = t0 + subStep ; for ( int i = 0 ; i < y0 . length ; ++ i ) { yEnd [ i ] = y0 [ i ] + subStep * f [ 0 ] [ i ] ; } f [ 1 ] = computeDerivatives ( t , yEnd ) ; final double [ ] yTmp = y0 . clone ( ) ; for ( int j = 1 ; j < n ; ++ j ) { if ( 2 * j == n ) { System . arraycopy ( yEnd , 0 , yMiddle , 0 , y0 . length ) ; } t += subStep ; for ( int i = 0 ; i < y0 . length ; ++ i ) { final double middle = yEnd [ i ] ; yEnd [ i ] = yTmp [ i ] + subStep2 * f [ j ] [ i ] ; yTmp [ i ] = middle ; } f [ j + 1 ] = computeDerivatives ( t , yEnd ) ; if ( performTest && ( j <= maxChecks ) && ( k < maxIter ) ) { double initialNorm = 0.0 ; for ( int l = 0 ; l < scale . length ; ++ l ) { final double ratio = f [ 0 ] [ l ] / scale [ l ] ; initialNorm += ratio * ratio ; } double deltaNorm = 0.0 ; for ( int l = 0 ; l < scale . length ; ++ l ) { final double ratio = ( f [ j + 1 ] [ l ] - f [ 0 ] [ l ] ) / scale [ l ] ; deltaNorm += ratio * ratio ; } if ( deltaNorm > 4 * FastMath . max ( 1.0e-15 , initialNorm ) ) { return false ; } } } for ( int i = 0 ; i < y0 . length ; ++ i ) { yEnd [ i ] = 0.5 * ( yTmp [ i ] + yEnd [ i ] + subStep * f [ n ] [ i ] ) ; } return true ; }

Realice la integración en un paso usando subposiciones de un método de punto medio modificado.


private void readObject  ( ObjectInputStream s ) throws IOException , ClassNotFoundException  { s . defaultReadObject ( ) ; try { init ( ) ; } catch ( RuntimeException e ) { if ( e instanceof NullPointerException || e instanceof IllegalArgumentException ) { InvalidObjectException ee = new InvalidObjectException ( e . getMessage ( ) ) ; ee . initCause ( e ) ; throw ee ; } throw e ; } }

Verifica la sintaxis del nombre de destino y recrea cualquier estado transitorio.


public void addRetype  ( RetypeableInstruction i ) { instructionsToRetype . add ( i ) ; }

Agregue una instrucción rehisable a este cuerpo.


public static long readSwappedLong  ( byte [ ] data , int offset ) { long low = ( ( data [ offset + 0 ] & 0xff ) << 0 ) + ( ( data [ offset + 1 ] & 0xff ) << 8 ) + ( ( data [ offset + 2 ] & 0xff ) << 16 ) + ( ( data [ offset + 3 ] & 0xff ) << 24 ) ; long high = ( ( data [ offset + 4 ] & 0xff ) << 0 ) + ( ( data [ offset + 5 ] & 0xff ) << 8 ) + ( ( data [ offset + 6 ] & 0xff ) << 16 ) + ( ( data [ offset + 7 ] & 0xff ) << 24 ) ; return ( high << 32 ) + ( 0xffffffffL & low ) ; }

Lee un valor "largo" de una matriz de bytes a un desplazamiento determinado.El valor se convierte en el sistema de endian opuesto al leer.


public static SM_SYSTEM_MESSAGE STR_SKILL_SUCC_SummonHoming_A_TO_B  ( String skillcaster , String value0 , String skilltarget , String skillname ) { return new SM_SYSTEM_MESSAGE ( 1201036 , skillcaster , value0 , skilltarget , skillname ) ; }

[% Skillcaster] ha convocado a% 0 para atacar [% SkillTarget] usando [% SkillName].


public PlacesCheckinQuery services  ( List < PlacesCheckinService > value ) { return unsafeParam ( "services" , value ) ; }

Lista de servicios o sitios web (por ejemplo, "Twitter", "Facebook") a la que se exportará el check-in, si el usuario ha configurado la opción respectiva.


@ Deprecated public FortSearchResponse searchFort  ( FortData fortData ) throws LoginFailedException , RemoteServerException  { FortSearchMessage reqMsg = FortSearchMessage . newBuilder ( ) . setFortId ( fortData . getId ( ) ) . setFortLatitude ( fortData . getLatitude ( ) ) . setFortLongitude ( fortData . getLongitude ( ) ) . setPlayerLatitude ( api . getLatitude ( ) ) . setPlayerLongitude ( api . getLongitude ( ) ) . build ( ) ; ServerRequest serverRequest = new ServerRequest ( RequestType . FORT_SEARCH , reqMsg ) ; api . getRequestHandler ( ) . sendServerRequests ( serverRequest ) ; FortSearchResponse response ; try { response = FortSearchResponse . parseFrom ( serverRequest . getData ( ) ) ; } catch ( InvalidProtocolBufferException e ) { throw new RemoteServerException ( e ) ; } return response ; }


public void removeColumnModelByName  ( String columnName ) { if ( TextUtils . isEmpty ( columnName ) ) { return ; } int indexToRemove = - 1 ; for ( int i = 0 ; i < columnModels . size ( ) ; i ++ ) { ColumnModel columnModel = columnModels . get ( i ) ; if ( columnName . equalsIgnoreCase ( columnModel . getColumnName ( ) ) ) { indexToRemove = i ; break ; } } if ( indexToRemove != - 1 ) { columnModels . remove ( indexToRemove ) ; } }

Eliminar un modelo de columna por el nombre de la columna especificado.


private List < Property > parseXmlProperties  ( String xmlString ) throws Exception { List < Property > properties = new ArrayList < > ( ) ; Serializer serializer = new Persister ( ) ; PropertyList propertyList = serializer . read ( PropertyList . class , xmlString ) ; for ( Property property : propertyList . getProperties ( ) ) { properties . add ( property ) ; } return properties ; }

Analice la representación XML de las propiedades de una clase de dispositivo (que proviene de la configuración) y devuélvala como una lista de propiedades.


protected boolean writeConstantPool  ( DataOutputStream dd ) throws IOException { cp_info cp ; int i ; boolean skipone = false ; for ( i = 1 ; i < constant_pool_count ; i ++ ) { if ( skipone ) { skipone = false ; continue ; } cp = constant_pool [ i ] ; dd . writeByte ( cp . tag ) ; switch ( cp . tag ) { case cp_info . CONSTANT_Class : dd . writeShort ( ( ( CONSTANT_Class_info ) cp ) . name_index ) ; break ; case cp_info . CONSTANT_Fieldref : dd . writeShort ( ( ( CONSTANT_Fieldref_info ) cp ) . class_index ) ; dd . writeShort ( ( ( CONSTANT_Fieldref_info ) cp ) . name_and_type_index ) ; break ; case cp_info . CONSTANT_Methodref : dd . writeShort ( ( ( CONSTANT_Methodref_info ) cp ) . class_index ) ; dd . writeShort ( ( ( CONSTANT_Methodref_info ) cp ) . name_and_type_index ) ; break ; case cp_info . CONSTANT_InterfaceMethodref : dd . writeShort ( ( ( CONSTANT_InterfaceMethodref_info ) cp ) . class_index ) ; dd . writeShort ( ( ( CONSTANT_InterfaceMethodref_info ) cp ) . name_and_type_index ) ; break ; case cp_info . CONSTANT_String : dd . writeShort ( ( ( CONSTANT_String_info ) cp ) . string_index ) ; break ; case cp_info . CONSTANT_Integer : dd . writeInt ( ( int ) ( ( CONSTANT_Integer_info ) cp ) . bytes ) ; break ; case cp_info . CONSTANT_Float : dd . writeInt ( ( int ) ( ( CONSTANT_Float_info ) cp ) . bytes ) ; break ; case cp_info . CONSTANT_Long : dd . writeInt ( ( int ) ( ( CONSTANT_Long_info ) cp ) . high ) ; dd . writeInt ( ( int ) ( ( CONSTANT_Long_info ) cp ) . low ) ; skipone = true ; break ; case cp_info . CONSTANT_Double : dd . writeInt ( ( int ) ( ( CONSTANT_Double_info ) cp ) . high ) ; dd . writeInt ( ( int ) ( ( CONSTANT_Double_info ) cp ) . low ) ; skipone = true ; break ; case cp_info . CONSTANT_NameAndType : dd . writeShort ( ( ( CONSTANT_NameAndType_info ) cp ) . name_index ) ; dd . writeShort ( ( ( CONSTANT_NameAndType_info ) cp ) . descriptor_index ) ; break ; case cp_info . CONSTANT_Utf8 : ( ( CONSTANT_Utf8_info ) cp ) . writeBytes ( dd ) ; break ; default : G . v ( ) . out . println ( "Unknown tag in constant pool: " + cp . tag ) ; return false ; } } return true ; }

Escribe el grupo constante actual al flujo dado.


public static < T extends  RealFieldElement < T >> T distance1 ( final Vector3D v1 , final FieldVector3D < T > v2 )  { return v2 . distance1 ( v1 ) ; }

Calcule la distancia entre dos vectores de acuerdo con la norma L <SUB> 1 </ SUB>.<p> Llamar a este método es equivalente a llamar: <Code> v1.subtract (v2) .getnorm1 () </ código> Excepto que no se construye un vector intermedio </ p>


public void reset  ( ) { m_root = null ; }

Limpia las referencias a las tuplas de gráficos.Se conservan el grupo y la visualización.


public Builder piecesSpacing  ( float piecesSpacing ) { this . piecesSpacing = piecesSpacing ; return this ; }

Establecer piezas espaciadas.Valor predeterminado: 40DP.


public AggregateConfig ( Configuration config , String [ ] configArgs ) throws ConfigurationException { specific = ConfigurationProvider . getInstance ( configArgs ) ; common = config ; }


public static boolean checkComplete  ( String directory , ShareSecurityCheck securityCheck , Intent intentResult ) { String meta = securityCheck . getMetaContentMap ( ) . get ( SO_MEAT_FILE ) ; if ( meta == null ) { return true ; } ArrayList < ShareBsDiffPatchInfo > libraryList = new ArrayList < > ( ) ; ShareBsDiffPatchInfo . parseDiffPatchInfo ( meta , libraryList ) ; if ( libraryList . isEmpty ( ) ) { return true ; } String libraryPath = directory + "/" + SO_PATH + "/" ; HashMap < String , String > libs = new HashMap < > ( ) ; for ( ShareBsDiffPatchInfo info : libraryList ) { if ( ! ShareBsDiffPatchInfo . checkDiffPatchInfo ( info ) ) { intentResult . putExtra ( ShareIntentUtil . INTENT_PATCH_PACKAGE_PATCH_CHECK , ShareConstants . ERROR_PACKAGE_CHECK_LIB_META_CORRUPTED ) ; ShareIntentUtil . setIntentReturnCode ( intentResult , ShareConstants . ERROR_LOAD_PATCH_PACKAGE_CHECK_FAIL ) ; return false ; } String middle = info . path + "/" + info . name ; libs . put ( middle , info . md5 ) ; } File libraryDir = new File ( libraryPath ) ; if ( ! libraryDir . exists ( ) || ! libraryDir . isDirectory ( ) ) { ShareIntentUtil . setIntentReturnCode ( intentResult , ShareConstants . ERROR_LOAD_PATCH_VERSION_LIB_DIRECTORY_NOT_EXIST ) ; return false ; } for ( String relative : libs . keySet ( ) ) { File libFile = new File ( libraryPath + relative ) ; if ( ! libFile . exists ( ) ) { ShareIntentUtil . setIntentReturnCode ( intentResult , ShareConstants . ERROR_LOAD_PATCH_VERSION_LIB_FILE_NOT_EXIST ) ; intentResult . putExtra ( ShareIntentUtil . INTENT_PATCH_MISSING_LIB_PATH , libFile . getAbsolutePath ( ) ) ; return false ; } } intentResult . putExtra ( ShareIntentUtil . INTENT_PATCH_LIBS_PATH , libs ) ; return true ; }

¿Todos los archivos de la biblioteca en el archivo meta existen?Cheque rápido, solo compruebe si existe


public void dumpMaryCART  ( CART cart , String destFile ) throws IOException { if ( cart == null ) throw new NullPointerException ( "Cannot dump null CART" ) ; if ( destFile == null ) throw new NullPointerException ( "No destination file" ) ; Log . d ( Mary . LOG , "Dumping CART in MaryCART format to " + destFile + " ..." ) ; DataOutputStream out = new DataOutputStream ( new BufferedOutputStream ( new FileOutputStream ( destFile ) ) ) ; MaryHeader hdr = new MaryHeader ( MaryHeader . CARTS ) ; hdr . writeTo ( out ) ; Properties props = cart . getProperties ( ) ; if ( props == null ) { out . writeShort ( 0 ) ; } else { ByteArrayOutputStream baos = new ByteArrayOutputStream ( ) ; props . store ( baos , null ) ; byte [ ] propData = baos . toByteArray ( ) ; out . writeShort ( propData . length ) ; out . write ( propData ) ; } cart . getFeatureDefinition ( ) . writeBinaryTo ( out ) ; dumpBinary ( cart . getRootNode ( ) , out ) ; out . close ( ) ; Log . d ( Mary . LOG , " ... done\n" ) ; }


public static String convertText  ( final ConversionMethod method , final byte [ ] text ) { switch ( method ) { case HEX_ENCODE : { return new String ( Hex . encodeHex ( text ) ) ; } case HEX_DECODE : { return ConversionUtils . hexToStringNoException ( ConversionUtils . arrayToString ( text ) ) ; } case BASE_64_ENCODE : { return Base64 . encodeBase64String ( text ) ; } case BASE_64_DECODE : { return new String ( Base64 . decodeBase64 ( text ) ) ; } default : return ConversionUtils . arrayToString ( text ) ; } }

Convierte el texto dado usando el método suministrado.


public boolean isXPath  ( ) { return false ; }

Devuelve verdadero si este valor es una ruta XML.


protected void drawCell  ( Graphics2D gc , double [ ] boundingBox , double correlationCoefficent ) { double centerX = boundingBox [ 0 ] + boundingBox [ 2 ] / 2 ; double centerY = boundingBox [ 1 ] + boundingBox [ 3 ] / 2 ; Color color = getChartColors ( ) . getHeatMapTable ( ) . getColor ( ( int ) Math . round ( 500.0 * ( correlationCoefficent + 1.0 ) ) , 1000 ) ; switch ( getMode ( ) ) { case Beans : { double width = 2 + Math . min ( boundingBox [ 2 ] , boundingBox [ 3 ] ) * ( correlationCoefficent + 1.0 ) / 2.0 ; double height = 2 + Math . min ( boundingBox [ 2 ] , boundingBox [ 3 ] ) * ( 1.0 - correlationCoefficent ) / 2.0 ; int x = ( int ) Math . round ( centerX - width / 2.0 ) ; int y = ( int ) Math . round ( centerY - height / 2.0 ) ; if ( correlationCoefficent >= 1 ) { gc . setColor ( color . darker ( ) ) ; gc . rotate ( Geometry . deg2rad ( - 45 ) , centerX , centerY ) ; gc . drawLine ( x , y , x + ( int ) Math . round ( width ) , y ) ; gc . rotate ( Geometry . deg2rad ( 45 ) , centerX , centerY ) ; } else if ( correlationCoefficent <= - 1 ) { gc . setColor ( color . darker ( ) ) ; gc . rotate ( Geometry . deg2rad ( 45 ) , centerX , centerY ) ; gc . drawLine ( x , y , x + ( int ) Math . round ( width ) , y ) ; gc . rotate ( Geometry . deg2rad ( - 45 ) , centerX , centerY ) ; } else { gc . setColor ( color ) ; gc . rotate ( Geometry . deg2rad ( - 45 ) , centerX , centerY ) ; gc . fillOval ( x , y , ( int ) Math . round ( width ) , ( int ) Math . round ( height ) ) ; gc . setColor ( color . darker ( ) ) ; gc . drawOval ( x , y , ( int ) Math . round ( width ) , ( int ) Math . round ( height ) ) ; gc . rotate ( Geometry . deg2rad ( 45 ) , centerX , centerY ) ; } break ; } case Circles : { double width = Math . min ( boundingBox [ 2 ] , boundingBox [ 3 ] ) ; double height = Math . min ( boundingBox [ 2 ] , boundingBox [ 3 ] ) ; double radius = Math . abs ( correlationCoefficent ) * Math . min ( width , height ) ; int x = ( int ) Math . round ( centerX - radius / 2.0 ) ; int y = ( int ) Math . round ( centerY - radius / 2.0 ) ; gc . setColor ( color ) ; gc . fillOval ( x , y , ( int ) Math . round ( radius ) , ( int ) Math . round ( radius ) ) ; gc . setColor ( color . darker ( ) ) ; gc . drawOval ( x , y , ( int ) Math . round ( radius ) , ( int ) Math . round ( radius ) ) ; break ; } case Squares : { double width = Math . min ( boundingBox [ 2 ] , boundingBox [ 3 ] ) * Math . abs ( correlationCoefficent ) ; double height = Math . min ( boundingBox [ 2 ] , boundingBox [ 3 ] ) * Math . abs ( correlationCoefficent ) ; int x = ( int ) Math . round ( centerX - width / 2.0 ) ; int y = ( int ) Math . round ( centerY - height / 2.0 ) ; gc . setColor ( color ) ; gc . fillRect ( x , y , ( int ) Math . round ( width ) , ( int ) Math . round ( height ) ) ; gc . setColor ( color . darker ( ) ) ; gc . drawRect ( x , y , ( int ) Math . round ( width ) , ( int ) Math . round ( height ) ) ; break ; } case Colors : { final double width = boundingBox [ 2 ] ; final double height = boundingBox [ 3 ] ; final double x = centerX - width / 2.0 ; final double y = centerY - height / 2.0 ; gc . setColor ( color ) ; if ( isGapBetweenBars ( ) && width > 3 && height > 3 ) { final Rectangle2D rect = new Rectangle2D . Double ( x + 1 , y + 1 , width - 2 , height - 2 ) ; gc . fill ( rect ) ; } else { final Rectangle2D rect = new Rectangle2D . Double ( x , y , width + 1 , height + 1 ) ; gc . fill ( rect ) ; if ( isShowVerticalGridLines ( ) ) { gc . setColor ( color . darker ( ) ) ; gc . draw ( rect ) ; } } break ; } case Numbers : { gc . setFont ( getFont ( ChartViewer . FontKeys . DrawFont . toString ( ) ) ) ; String label = String . format ( "%.3f" , correlationCoefficent ) ; Dimension labelSize = Basic . getStringSize ( gc , label , gc . getFont ( ) ) . getSize ( ) ; int x = ( int ) Math . round ( centerX - labelSize . width / 2.0 ) ; int y = ( int ) Math . round ( centerY ) ; gc . setColor ( color . darker ( ) ) ; gc . drawString ( label , x , y ) ; } } }


private void createLocalDecl  ( polyglot . ast . LocalDecl localDecl ) { String name = localDecl . name ( ) ; polyglot . types . LocalInstance localInst = localDecl . localInstance ( ) ; soot . Value lhs = createLocal ( localInst ) ; polyglot . ast . Expr expr = localDecl . init ( ) ; if ( expr != null ) { soot . Value rhs ; if ( expr instanceof polyglot . ast . ArrayInit ) { rhs = getArrayInitLocal ( ( polyglot . ast . ArrayInit ) expr , localInst . type ( ) ) ; } else { rhs = base ( ) . createAggressiveExpr ( expr , false , false ) ; } if ( rhs instanceof soot . jimple . ConditionExpr ) { rhs = handleCondBinExpr ( ( soot . jimple . ConditionExpr ) rhs ) ; } soot . jimple . AssignStmt stmt = soot . jimple . Jimple . v ( ) . newAssignStmt ( lhs , rhs ) ; body . getUnits ( ) . add ( stmt ) ; Util . addLnPosTags ( stmt , localDecl . position ( ) ) ; if ( localDecl . position ( ) != null ) { Util . addLnPosTags ( stmt . getLeftOpBox ( ) , localDecl . position ( ) . line ( ) , localDecl . position ( ) . endLine ( ) , localDecl . position ( ) . endColumn ( ) - name . length ( ) , localDecl . position ( ) . endColumn ( ) ) ; if ( expr != null ) { Util . addLnPosTags ( stmt , localDecl . position ( ) . line ( ) , expr . position ( ) . endLine ( ) , localDecl . position ( ) . column ( ) , expr . position ( ) . endColumn ( ) ) ; } else { Util . addLnPosTags ( stmt , localDecl . position ( ) . line ( ) , localDecl . position ( ) . endLine ( ) , localDecl . position ( ) . column ( ) , localDecl . position ( ) . endColumn ( ) ) ; } } else { } if ( expr != null ) { Util . addLnPosTags ( stmt . getRightOpBox ( ) , expr . position ( ) ) ; } } }


public static String readFile  ( final File file ) { try { return readFileWithExceptions ( file ) ; } catch ( IOException e ) { System . out . println ( ExceptionMessages . COULD_NOT_READ . with ( e ) ) ; } return null ; }

Lee el archivo dado.Devuelve NULL si el archivo no se puede leer.


private Tab createNewTab  ( LoadUrlParams loadUrlParams , TabModel . TabLaunchType type , Tab parent , int position , Intent intent ) { try { TraceEvent . begin ( "ChromeTabCreator.createNewTab" ) ; int parentId = parent != null ? parent . getId ( ) : Tab . INVALID_TAB_ID ; loadUrlParams . setUrl ( UrlUtilities . fixupUrl ( loadUrlParams . getUrl ( ) ) ) ; loadUrlParams . setTransitionType ( getTransitionType ( type ) ) ; int assignedTabId = intent == null ? Tab . INVALID_TAB_ID : IntentUtils . safeGetIntExtra ( intent , IntentHandler . EXTRA_TAB_ID , Tab . INVALID_TAB_ID ) ; AsyncTabCreationParams asyncParams = AsyncTabCreationParamsManager . remove ( assignedTabId ) ; WebContents webContents = asyncParams == null ? null : asyncParams . getWebContents ( ) ; boolean openInForeground = mOrderController . willOpenInForeground ( type , mIncognito ) || webContents != null ; TabDelegateFactory delegateFactory = new TabDelegateFactory ( ) ; Tab tab ; if ( webContents != null ) { Intent parentIntent = IntentUtils . safeGetParcelableExtra ( intent , IntentHandler . EXTRA_PARENT_INTENT ) ; parentId = IntentUtils . safeGetIntExtra ( intent , IntentHandler . EXTRA_PARENT_TAB_ID , parentId ) ; assert TabModelUtils . getTabIndexById ( mTabModel , assignedTabId ) == TabModel . INVALID_TAB_INDEX ; tab = Tab . createLiveTab ( assignedTabId , mActivity , mIncognito , mNativeWindow , type , parentId , ! openInForeground ) ; tab . initialize ( webContents , mTabContentManager , delegateFactory , ! openInForeground ) ; tab . setParentIntent ( parentIntent ) ; webContents . resumeLoadingCreatedWebContents ( ) ; } else if ( ! openInForeground && SysUtils . isLowEndDevice ( ) ) { tab = Tab . createTabForLazyLoad ( mActivity , mIncognito , mNativeWindow , type , parentId , loadUrlParams ) ; tab . initialize ( null , mTabContentManager , delegateFactory , ! openInForeground ) ; mTabSaver . addTabToSaveQueue ( tab ) ; } else { webContents = WarmupManager . getInstance ( ) . hasPrerenderedUrl ( loadUrlParams . getUrl ( ) ) ? WarmupManager . getInstance ( ) . takePrerenderedWebContents ( ) : null ; tab = Tab . createLiveTab ( Tab . INVALID_TAB_ID , mActivity , mIncognito , mNativeWindow , type , parentId , ! openInForeground ) ; tab . initialize ( webContents , mTabContentManager , delegateFactory , ! openInForeground ) ; tab . loadUrl ( loadUrlParams ) ; } tab . getTabRedirectHandler ( ) . updateIntent ( intent ) ; if ( intent != null && intent . hasExtra ( ServiceTabLauncher . LAUNCH_REQUEST_ID_EXTRA ) ) { ServiceTabLauncher . onWebContentsForRequestAvailable ( intent . getIntExtra ( ServiceTabLauncher . LAUNCH_REQUEST_ID_EXTRA , 0 ) , tab . getWebContents ( ) ) ; } mTabModel . addTab ( tab , position , type ) ; return tab ; } finally { TraceEvent . end ( "ChromeTabCreator.createNewTab" ) ; } }

Crea una nueva pestaña y publicaciones a UI.


@ Override public void characters  ( char [ ] ch , int start , int len ) throws SAXException { if ( ! cdataElement ) { if ( mIgnoreChars ) { writeText4Links ( ) ; writeEscUTF16 ( new String ( ch ) , start , len , false ) ; } else { collectText4Links ( ch , start , len ) ; } } else { writeText4Links ( ) ; for ( int i = start ; i < start + len ; i ++ ) { write ( ch [ i ] ) ; } } super . characters ( ch , start , len ) ; }

Escribir datos de caracteres.<P> Pase el evento en la cadena de filtro para su posterior procesamiento.


@ Override public void afterSdkPathChange  ( @ NotNull File sdkPath , @ NotNull Project project ) { if ( ! isBuildWithGradle ( project ) ) { return ; } LocalProperties localProperties ; try { localProperties = new LocalProperties ( project ) ; } catch ( IOException e ) { logAndShowErrorWhenUpdatingLocalProperties ( project , e , "read" , sdkPath ) ; return ; } if ( ! filesEqual ( sdkPath , localProperties . getAndroidSdkPath ( ) ) ) { try { localProperties . setAndroidSdkPath ( sdkPath ) ; localProperties . save ( ) ; } catch ( IOException e ) { logAndShowErrorWhenUpdatingLocalProperties ( project , e , "update" , sdkPath ) ; return ; } } if ( ! ApplicationManager . getApplication ( ) . isUnitTestMode ( ) ) { GradleProjectImporter . getInstance ( ) . requestProjectSync ( project , null ) ; } }

Actualiza la ruta del administrador SDK en el archivo local.properties del proyecto, solo si la nueva ruta y la ruta en el archivo son diferentes.Este método solicitará una sincronización de proyecto, a menos que se ocurre un error al actualizar el archivo local.properties.


@ Override public void onButtonClicked  ( boolean isPrimaryButton ) { onButtonClicked ( ActionType . OK ) ; }

Llamado cuando se hace clic en el botón.Notifica al infobar nativo, que cierra el infobar.


@ RequestMapping ( value = "/race-data" , method = RequestMethod . PUT , produces = MediaType . APPLICATION_JSON_VALUE ) @ Timed public ResponseEntity < RaceData > updateRaceData  ( @ RequestBody RaceData raceData ) throws URISyntaxException { log . debug ( "REST request to update RaceData : {}" , raceData ) ; if ( raceData . getRaceDataId ( ) == null ) { return createRaceData ( raceData ) ; } RaceData result = raceDataRepository . save ( raceData ) ; return ResponseEntity . ok ( ) . headers ( HeaderUtil . createEntityUpdateAlert ( "raceData" , raceData . getRaceDataId ( ) . toString ( ) ) ) . body ( result ) ; }

PUT / RACE-DATOS: Actualiza un Racedata existente.


private boolean resizeAndSaveImage  ( File targetFile , int maxWidth , int maxHeight ) throws IOException { boolean saved = false ; ImageSize targetImageSize = new ImageSize ( maxWidth , maxHeight ) ; DisplayImageOptions specialOptions = new DisplayImageOptions . Builder ( ) . cloneFrom ( options ) . imageScaleType ( ImageScaleType . IN_SAMPLE_INT ) . build ( ) ; ImageDecodingInfo decodingInfo = new ImageDecodingInfo ( memoryCacheKey , ImageDownloader . Scheme . FILE . wrap ( targetFile . getAbsolutePath ( ) ) , targetImageSize , ViewScaleType . FIT_INSIDE , getDownloader ( ) , specialOptions ) ; Bitmap bmp = decoder . decode ( decodingInfo ) ; if ( bmp != null && configuration . processorForDiscCache != null ) { log ( LOG_PROCESS_IMAGE_BEFORE_CACHE_ON_DISC ) ; bmp = configuration . processorForDiscCache . process ( bmp ) ; if ( bmp == null ) { L . e ( ERROR_PROCESSOR_FOR_DISC_CACHE_NULL , memoryCacheKey ) ; } } if ( bmp != null ) { OutputStream os = new BufferedOutputStream ( new FileOutputStream ( targetFile ) , BUFFER_SIZE ) ; try { bmp . compress ( configuration . imageCompressFormatForDiscCache , configuration . imageQualityForDiscCache , os ) ; } finally { IoUtils . closeSilently ( os ) ; } bmp . recycle ( ) ; } return true ; }

Decodifica el archivo de imagen en mapa de bits, redimensionarlo y guardarlo de nuevo


public boolean isPureQuaternion  ( double eps ) { return FastMath . abs ( getQ0 ( ) ) <= eps ; }

Comprueba si la instancia es un cuaternión puro dentro de una tolerancia dada.


public boolean gotoFirst  ( ) { countCurrent = 0 ; if ( ! searchInCollapsed ) { final List < Integer > list = classificationViewer . computeDisplayedIdsInSearchOrder ( ) ; currentIterator = list . iterator ( ) ; numberOfObjects = list . size ( ) ; } else { final List < Integer > list = classificationViewer . computeAllIdsInSearchOrder ( ) ; currentIterator = list . iterator ( ) ; numberOfObjects = list . size ( ) ; } currentId = ( currentIterator . hasNext ( ) ? currentIterator . next ( ) : null ) ; return isCurrentSet ( ) ; }


public Settings ( PokemonGo api ) { this . api = api ; this . mapSettings = new MapSettings ( ) ; this . levelUpSettings = new LevelUpSettings ( ) ; this . fortSettings = new FortSettings ( ) ; this . inventorySettings = new InventorySettings ( ) ; this . gpsSettings = new GpsSettings ( ) ; this . hash = new String ( ) ; }

Objeto de configuración que tiene un aspecto de configuración diferente del juego.Se puede utilizar para simular el comportamiento real de la aplicación.


public static SM_SYSTEM_MESSAGE STR_MSG_DICE_UNAUTHORIZED  ( String value0 ) { return new SM_SYSTEM_MESSAGE ( 1300783 , value0 ) ; }


private static int c  ( int i , int j , int m , int n , long cmn , boolean strict ) { if ( strict ) { return FastMath . abs ( i * ( long ) n - j * ( long ) m ) <= cmn ? 1 : 0 ; } return FastMath . abs ( i * ( long ) n - j * ( long ) m ) < cmn ? 1 : 0 ; }

La función C (I, J) definida en [4] (clase Javadoc), fórmula (5.5).definido para volver 1 si | I / N - J / M |<= C;0 de lo contrario.Aquí c se reduce y se recodifica como un largo para evitar errores de redondeo en las pruebas de comparación, por lo que lo que realmente se prueba es | Im - Jn |<= CMN.


public static String toString  ( URI uri , String encoding ) throws IOException { return toString ( uri , Charsets . toCharset ( encoding ) ) ; }


public static String prepareExpression  ( String expression ) { String result = StringUtil . convertOperatorSubstitutions ( expression ) ; result = result . replace ( "[]" , "['add']" ) ; int openBrace = result . indexOf ( "[+" ) ; int closeBrace = ( openBrace == - 1 ? - 1 : result . indexOf ( ']' , openBrace ) ) ; if ( closeBrace != - 1 ) { String base = result . substring ( 0 , openBrace ) ; String property = result . substring ( openBrace + 2 , closeBrace ) . trim ( ) ; String end = result . substring ( closeBrace + 1 ) ; result = base + "['insert@" + property + "']" + end ; } return result ; }

Prepara una expresión para la evaluación por UEL. <P> La sintaxis OFBIX se convierte en la sintaxis compatible con UEL y se devuelve la expresión resultante. </ P>


private DeferredFileOutputStream ( int threshold , File outputFile , String prefix , String suffix , File directory ) { super ( threshold ) ; this . outputFile = outputFile ; memoryOutputStream = new ByteArrayOutputStream ( ) ; currentOutputStream = memoryOutputStream ; this . prefix = prefix ; this . suffix = suffix ; this . directory = directory ; }

Construye una instancia de esta clase que activará un evento en el umbral especificado, y guardará datos a un archivo más allá de ese punto.


public static Double calcMaxDecisions  ( final long min_impressions , final long max_impressions ) { if ( min_impressions <= 0 ) { throw new IllegalArgumentException ( "Minimum number of unique impressions must be positive." ) ; } if ( max_impressions <= 0 ) { throw new IllegalArgumentException ( "Maximum number of unique impressions must be positive." ) ; } return log ( 1.0 * max_impressions / min_impressions ) ; }

Calcula el factor de escala que se utilizará para ajustar el monitoreo continuo de experimentos.El factor de escala se puede considerar como el número máximo de puntos de decisión 'independientes' que podrían existir durante el curso de un experimento.


public int modify_file1  ( String appender_file_id , long file_offset , byte [ ] file_buff ) throws IOException , MyException { String [ ] parts = new String [ 2 ] ; this . errno = this . split_file_id ( appender_file_id , parts ) ; if ( this . errno != 0 ) { return this . errno ; } return this . modify_file ( parts [ 0 ] , parts [ 1 ] , file_offset , file_buff ) ; }

Modifique el archivo de la apertura al servidor de almacenamiento (por File Buff)


public static void validateClusterSchemaAttributes  ( SpaceURL spaceURL ) throws MalformedURLException  { if ( spaceURL . containsKey ( SpaceURL . CLUSTER_TOTAL_MEMBERS ) ) { String [ ] clusterTotalMembers = getClusterMembers ( spaceURL . getProperty ( SpaceURL . CLUSTER_TOTAL_MEMBERS ) ) ; if ( clusterTotalMembers . length == 1 && Integer . parseInt ( clusterTotalMembers [ 0 ] ) <= 1 ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_TOTAL_MEMBERS + "> attribute must be larger than 1" + " in the space URL: " + spaceURL ) ; } } if ( spaceURL . containsKey ( SpaceURL . CLUSTER_SCHEMA ) && ! ( spaceURL . containsKey ( SpaceURL . CLUSTER_TOTAL_MEMBERS ) ) ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_SCHEMA + "> attribute must be used together with the <" + SpaceURL . CLUSTER_TOTAL_MEMBERS + "> attribute " + "in the space URL: " + spaceURL ) ; } if ( spaceURL . containsKey ( SpaceURL . CLUSTER_TOTAL_MEMBERS ) && ! ( spaceURL . containsKey ( SpaceURL . CLUSTER_SCHEMA ) ) ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_TOTAL_MEMBERS + "> attribute must be used together with the <" + SpaceURL . CLUSTER_SCHEMA + "> attribute " + "in the space URL: " + spaceURL ) ; } if ( spaceURL . containsKey ( SpaceURL . CLUSTER_SCHEMA ) && spaceURL . containsKey ( SpaceURL . CLUSTER_TOTAL_MEMBERS ) ) { if ( ! spaceURL . containsKey ( SpaceURL . CLUSTER_MEMBER_ID ) ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_SCHEMA + "=" + spaceURL . getProperty ( SpaceURL . CLUSTER_SCHEMA ) + "> attribute must be used together with the <" + SpaceURL . CLUSTER_MEMBER_ID + "> attribute in the space URL: " + spaceURL ) ; } String clusterSchema = spaceURL . getProperty ( SpaceURL . CLUSTER_SCHEMA ) ; String totalMembers = spaceURL . getProperty ( SpaceURL . CLUSTER_TOTAL_MEMBERS ) ; String [ ] totalMembersArray = getClusterMembers ( totalMembers ) ; if ( totalMembersArray . length > 1 ) { if ( ClusterXML . supportsBackup ( clusterSchema ) ) { try { int pNum = Integer . valueOf ( totalMembersArray [ 0 ] ) . intValue ( ) ; int bNum = Integer . valueOf ( totalMembersArray [ 1 ] ) . intValue ( ) ; if ( pNum < 1 || bNum < 0 ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_SCHEMA + "=" + clusterSchema + "> attribute must be used together with total_members attribute in the following format " + "total_members={number of primary instances, number of backup instances per primary} " + "in the space URL: " + spaceURL + ".\nThe number of primary instances must be greater than 0 and " + ".\nthe number of number of backup instances per primary must not be less than 0." ) ; } } catch ( NumberFormatException e ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_SCHEMA + "=" + clusterSchema + "> attribute must be used together with the total_members attribute in the following format " + "total_members={number of primary instances, number of backup instances per primary} " + "in the space URL: " + spaceURL + ".\nThe number of primary instances must be greater than 0 and " + ".\nthe number of number of backup instances per primary must not be less than 0." ) ; } } else { int bNum = Integer . valueOf ( totalMembersArray [ 1 ] ) . intValue ( ) ; if ( bNum > 0 ) throw new SpaceURLValidationException ( "The <" + SpaceURL . CLUSTER_SCHEMA + "=" + clusterSchema + "> attribute must be used together with the total_members attribute in the following format " + "total_members={number of primary instances} " + "in the space URL: " + spaceURL + ".\nOnly cluster_schema which ends with " + ClusterXML . CLUSTER_SCHEMA_NAME_PARTITIONED + " or " + ClusterXML . CLUSTER_SCHEMA_NAME_PRIMARY_BACKUP + " \ncan have total_member attribute in the following format " + "total_members={number of primary instances, number of backup instances per primary}." ) ; } } } String updateModeStr = spaceURL . getProperty ( SpaceURL . LOCAL_CACHE_UPDATE_MODE ) ; if ( updateModeStr != null ) { int updateMode = Integer . valueOf ( updateModeStr ) ; if ( updateMode != SpaceURL . UPDATE_MODE_PULL && updateMode != SpaceURL . UPDATE_MODE_PUSH ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . LOCAL_CACHE_UPDATE_MODE + "> attribute must be equal to " + SpaceURL . UPDATE_MODE_PULL + " or " + SpaceURL . UPDATE_MODE_PUSH + " in the space URL: " + spaceURL ) ; } } State state = ( State ) spaceURL . getLookupAttribute ( SpaceURL . STATE ) ; if ( state != null ) { if ( ! state . state . equalsIgnoreCase ( SpaceURL . STATE_STARTED ) && ! state . state . equalsIgnoreCase ( SpaceURL . STATE_STOPPED ) ) { throw new SpaceURLValidationException ( "The <" + SpaceURL . STATE + "> attribute must be equal to " + SpaceURL . STATE_STARTED + " or " + SpaceURL . STATE_STOPPED + " in the space URL: " + spaceURL ) ; } } }

Valida varias combinaciones espaciales con el clúster_schema, TOTAL_MEMBERS son y los argumentos de Backup_ID.


public IllConditionedOperatorException ( final double cond ) { super ( org . hipparchus . migration . exception . util . LocalizedFormats . ILL_CONDITIONED_OPERATOR , cond ) ; }


public static PrettyPrint indentWithTabs  ( ) { return new PrettyPrint ( new char [ ] { '\t' } ) ; }

No rompa las líneas, pero aún inserte espacio en blanco entre los valores.


public void write  ( OutputStream os ) throws DataIOException { try { PrintStream out = new PrintStream ( new BufferedOutputStream ( os ) ) ; for ( int i = 0 ; i < names . length ; ++ i ) { out . print ( names [ i ] ) ; out . print ( '\t' ) ; out . print ( cols [ i + 1 ] - cols [ i ] ) ; out . println ( ) ; } } catch ( Exception e ) { throw new DataIOException ( e ) ; } }

Escribe esta descripción de esquema a la corriente de salida dada.


@ Override public void init  ( String [ ] args , String name , String configFile ) throws ContainerException { this . name = name ; this . configFile = configFile ; this . stores = new LinkedHashMap < Store , Session > ( ) ; this . pollTimer = Executors . newScheduledThreadPool ( 1 ) ; }


public MullerSolver ( ) { this  ( DEFAULT_ABSOLUTE_ACCURACY ) ; }

Construir un solver con precisión predeterminada (1E-6).


protected static LazyNode cObject  ( int index ) { return new LazyNode ( OBJECT , index ) ; }

Método de conveniencia para crear un nuevo token con el tipo de tipo en objeto y con el índice de inicio establecido en el índice dado.


public CASCGraph ( ) { super ( 1 , 1 ) ; hVertexTypes = new HashMap ( ) ; }


@ Override public StringBuffer format  ( final long value , final StringBuffer buffer , final FieldPosition position ) { return format ( Long . valueOf ( value ) , buffer , position ) ; }

Los formats tienen un valor largo como una fracción y agregan el resultado a un stringBuffer.


public static void main  ( String [ ] args ) throws IOException { String xmlfile = null ; int debuglevel = 0 ; int maxErrs = 10 ; boolean nsAware = true ; boolean validating = true ; boolean showWarnings = ( debuglevel > 2 ) ; boolean showErrors = true ; Vector catalogFiles = new Vector ( ) ; for ( int i = 0 ; i < args . length ; i ++ ) { if ( args [ i ] . equals ( "-c" ) ) { ++ i ; catalogFiles . add ( args [ i ] ) ; continue ; } if ( args [ i ] . equals ( "-w" ) ) { validating = false ; continue ; } if ( args [ i ] . equals ( "-v" ) ) { validating = true ; continue ; } if ( args [ i ] . equals ( "-n" ) ) { nsAware = false ; continue ; } if ( args [ i ] . equals ( "-N" ) ) { nsAware = true ; continue ; } if ( args [ i ] . equals ( "-d" ) ) { ++ i ; String debugstr = args [ i ] ; try { debuglevel = Integer . parseInt ( debugstr ) ; if ( debuglevel >= 0 ) { debug . setDebug ( debuglevel ) ; showWarnings = ( debuglevel > 2 ) ; } } catch ( Exception e ) { } continue ; } if ( args [ i ] . equals ( "-E" ) ) { ++ i ; String errstr = args [ i ] ; try { int errs = Integer . parseInt ( errstr ) ; if ( errs >= 0 ) { maxErrs = errs ; } } catch ( Exception e ) { } continue ; } xmlfile = args [ i ] ; } if ( xmlfile == null ) { System . out . println ( "Usage: org.apache.xml.resolver.apps.xparse [opts] xmlfile" ) ; System . exit ( 1 ) ; } ResolvingParser . validating = validating ; ResolvingParser . namespaceAware = nsAware ; ResolvingParser reader = new ResolvingParser ( ) ; Catalog catalog = reader . getCatalog ( ) ; for ( int count = 0 ; count < catalogFiles . size ( ) ; count ++ ) { String file = ( String ) catalogFiles . elementAt ( count ) ; catalog . parseCatalog ( file ) ; } XParseError xpe = new XParseError ( showErrors , showWarnings ) ; xpe . setMaxMessages ( maxErrs ) ; reader . setErrorHandler ( xpe ) ; String parseType = validating ? "validating" : "well-formed" ; String nsType = nsAware ? "namespace-aware" : "namespace-ignorant" ; if ( maxErrs > 0 ) { System . out . println ( "Attempting " + parseType + ", " + nsType + " parse" ) ; } Date startTime = new Date ( ) ; try { reader . parse ( xmlfile ) ; } catch ( SAXException sx ) { System . out . println ( "SAX Exception: " + sx ) ; } catch ( Exception e ) { e . printStackTrace ( ) ; } Date endTime = new Date ( ) ; long millisec = endTime . getTime ( ) - startTime . getTime ( ) ; long secs = 0 ; long mins = 0 ; long hours = 0 ; if ( millisec > 1000 ) { secs = millisec / 1000 ; millisec = millisec % 1000 ; } if ( secs > 60 ) { mins = secs / 60 ; secs = secs % 60 ; } if ( mins > 60 ) { hours = mins / 60 ; mins = mins % 60 ; } if ( maxErrs > 0 ) { System . out . print ( "Parse " ) ; if ( xpe . getFatalCount ( ) > 0 ) { System . out . print ( "failed " ) ; } else { System . out . print ( "succeeded " ) ; System . out . print ( "(" ) ; if ( hours > 0 ) { System . out . print ( hours + ":" ) ; } if ( hours > 0 || mins > 0 ) { System . out . print ( mins + ":" ) ; } System . out . print ( secs + "." + millisec ) ; System . out . print ( ") " ) ; } System . out . print ( "with " ) ; int errCount = xpe . getErrorCount ( ) ; int warnCount = xpe . getWarningCount ( ) ; if ( errCount > 0 ) { System . out . print ( errCount + " error" ) ; System . out . print ( errCount > 1 ? "s" : "" ) ; System . out . print ( " and " ) ; } else { System . out . print ( "no errors and " ) ; } if ( warnCount > 0 ) { System . out . print ( warnCount + " warning" ) ; System . out . print ( warnCount > 1 ? "s" : "" ) ; System . out . print ( "." ) ; } else { System . out . print ( "no warnings." ) ; } System . out . println ( "" ) ; } if ( xpe . getErrorCount ( ) > 0 ) { System . exit ( 1 ) ; } }


public void partitionWithPercent  ( boolean withPercent ) { this . withPercent = withPercent ; if ( withPercent ) chartUtils = ChartHelper . generateArcWithPercent ( chartData ) ; else chartUtils = ChartHelper . generateArc ( chartData ) ; animateValue = - 1 ; invalidate ( ) ; }

Esta propiedad definirá el ancho de las particiones (igual o acc. Al porcentaje)


public void testCache  ( ) throws Exception  { FileDownloader downloader = Mockito . mock ( FileDownloader . class ) ; Mockito . when ( downloader . download ( Matchers . any ( File . class ) ) ) . thenReturn ( ImmutableList . of ( Pair . create ( myDistributionFile , myDescription ) ) ) ; DistributionService service = new DistributionService ( downloader , CACHE_PATH , myDistributionFileUrl ) ; service . getSupportedDistributionForApiLevel ( 19 ) ; service . getDistributionForApiLevel ( 21 ) ; Mockito . verify ( downloader ) . download ( Matchers . any ( File . class ) ) ; }

Prueba que no descargamos en cada solicitud


public long optLong  ( int index , long defaultValue ) { LazyNode token = getOptionalValueToken ( index ) ; if ( token == null ) return defaultValue ; if ( token . type == LazyNode . VALUE_NULL ) return defaultValue ; return token . getLongValue ( cbuf ) ; }

Devuelve el valor prolongado almacenado en el índice dado o el valor predeterminado si no hubo tal valor.


private static void rethrowAsProperlyTypedException  ( Throwable throwable ) throws IOException , ConfigurationException  { if ( throwable != null ) { Throwables . propagateIfPossible ( throwable , IOException . class , ConfigurationException . class ) ; throw new IllegalStateException ( throwable ) ; } }


public PhotosCreateAlbumQuery commentsDisabled  ( Boolean value ) { return unsafeParam ( "comments_disabled" , value ) ; }


private double [ ] [ ] newPointAndDirection  ( double [ ] p , double [ ] d , double optimum ) { final int n = p . length ; final double [ ] nP = new double [ n ] ; final double [ ] nD = new double [ n ] ; for ( int i = 0 ; i < n ; i ++ ) { nD [ i ] = d [ i ] * optimum ; nP [ i ] = p [ i ] + nD [ i ] ; } final double [ ] [ ] result = new double [ 2 ] [ ] ; result [ 0 ] = nP ; result [ 1 ] = nD ; return result ; }

Calcule un nuevo punto (en el espacio original) y un nuevo vector de dirección, resultante de la búsqueda de línea.


@ Override public Node previousSibling  ( ) { if ( fCurrentNode == null ) return null ; Node node = getPreviousSibling ( fCurrentNode ) ; if ( node != null ) { fCurrentNode = node ; } return node ; }

Devuelva el nodo de hermano anterior desde el nodo actual, después de aplicar el filtro, Whattowow.Si el resultado no es nulo, configure el nodo actual.


@ Override public int [ ] makeCumulativeTestPoints  ( ) { return makeDensityTestPoints ( ) ; }

Crea los valores de entrada de prueba de prueba de densidad de probabilidad acumulativos predeterminados


@ Override public WebElement findElement  ( ) { WebElement context = scopeFactory . createLocator ( scopeField ) . findElement ( ) ; return new DefaultElementLocator ( context , searchField ) . findElement ( ) ; }

Construye un alcance fuera de la fábrica de alcance y el campo principal, luego busca el campo inyectado en este alcance.


public DeadLockDetector ( int sleepTime , byte doWhenDL ) { super ( "DeadLockDetector" ) ; this . sleepTime = sleepTime * 1000 ; this . tmx = ManagementFactory . getThreadMXBean ( ) ; this . doWhenDL = doWhenDL ; }

Crea un nuevo punto muerto con valores dados.


private void onCreateFolderOperationFinish  ( CreateFolderOperation operation , RemoteOperationResult result ) { if ( result . isSuccess ( ) ) { String remotePath = operation . getRemotePath ( ) . substring ( 0 , operation . getRemotePath ( ) . length ( ) - 1 ) ; String newFolder = remotePath . substring ( remotePath . lastIndexOf ( "/" ) + 1 ) ; mParents . push ( newFolder ) ; populateDirectoryList ( ) ; } else { try { Toast msg = Toast . makeText ( this , ErrorMessageAdapter . getErrorCauseMessage ( result , operation , getResources ( ) ) , Toast . LENGTH_LONG ) ; msg . show ( ) ; } catch ( NotFoundException e ) { Log_OC . e ( TAG , "Error while trying to show fail message " , e ) ; } } }

Actualiza la vista asociada a la actividad después del final de una operación que intenta crear una nueva carpeta


@ Override public double nextNormalizedDouble  ( ) { double omega = - FastMath . log ( generator . nextDouble ( ) ) ; double phi = FastMath . PI * ( generator . nextDouble ( ) - 0.5 ) ; if ( alpha == 2d ) { return FastMath . sqrt ( 2d * omega ) * FastMath . sin ( phi ) ; } double x ; if ( beta == 0d ) { if ( alpha == 1d ) { x = FastMath . tan ( phi ) ; } else { x = FastMath . pow ( omega * FastMath . cos ( ( 1 - alpha ) * phi ) , 1d / alpha - 1d ) * FastMath . sin ( alpha * phi ) / FastMath . pow ( FastMath . cos ( phi ) , 1d / alpha ) ; } } else { double cosPhi = FastMath . cos ( phi ) ; if ( FastMath . abs ( alpha - 1d ) > 1e-8 ) { double alphaPhi = alpha * phi ; double invAlphaPhi = phi - alphaPhi ; x = ( FastMath . sin ( alphaPhi ) + zeta * FastMath . cos ( alphaPhi ) ) / cosPhi * ( FastMath . cos ( invAlphaPhi ) + zeta * FastMath . sin ( invAlphaPhi ) ) / FastMath . pow ( omega * cosPhi , ( 1 - alpha ) / alpha ) ; } else { double betaPhi = FastMath . PI / 2 + beta * phi ; x = 2d / FastMath . PI * ( betaPhi * FastMath . tan ( phi ) - beta * FastMath . log ( FastMath . PI / 2d * omega * cosPhi / betaPhi ) ) ; if ( alpha != 1d ) { x += beta * FastMath . tan ( FastMath . PI * alpha / 2 ) ; } } } return x ; }

Generar un escalar aleatorio con cero ubicación y escala de unidad.


private boolean clobberCurrentDocument  ( String url , boolean hasUserGesture ) { boolean shouldOpenNewTab = IntentUtils . safeGetBooleanExtra ( getIntent ( ) , Browser . EXTRA_CREATE_NEW_TAB , false ) ; String applicationId = IntentUtils . safeGetStringExtra ( getIntent ( ) , Browser . EXTRA_APPLICATION_ID ) ; if ( shouldOpenNewTab || ! getPackageName ( ) . equals ( applicationId ) ) return false ; int tabId = ChromeApplication . getDocumentTabModelSelector ( ) . getCurrentTabId ( ) ; if ( tabId == Tab . INVALID_TAB_ID ) return false ; LoadUrlParams params = new LoadUrlParams ( url , PageTransition . LINK | PageTransition . FROM_API ) ; params . setHasUserGesture ( hasUserGesture ) ; AsyncTabCreationParams data = new AsyncTabCreationParams ( params , new Intent ( getIntent ( ) ) ) ; AsyncTabCreationParamsManager . add ( tabId , data ) ; if ( ! relaunchTask ( tabId ) ) { AsyncTabCreationParamsManager . remove ( tabId ) ; return false ; } return true ; }

Si es necesario, intenta destruir la pestaña de la documentación actual con la URL dada.


public void removeEntry  ( Remote object ) { Entry entry = _objMap . remove ( object ) ; _objIdMap . remove ( entry . m_ObjectId ) ; }

Elimina la entrada correspondiente al objeto especificado.


private String downloadPacContent  ( String url ) throws IOException { if ( url == null ) { throw new IOException ( "Invalid PAC script URL: null" ) ; } setPacProxySelectorEnabled ( false ) ; HttpURLConnection con = null ; try { con = setupHTTPConnection ( url ) ; if ( con . getResponseCode ( ) != 200 ) { throw new IOException ( "Server returned: " + con . getResponseCode ( ) + " " + con . getResponseMessage ( ) ) ; } this . expireAtMillis = con . getExpiration ( ) ; BufferedReader r = getReader ( con ) ; String result = readAllContent ( r ) ; r . close ( ) ; return result ; } finally { setPacProxySelectorEnabled ( true ) ; if ( con != null ) { con . disconnect ( ) ; } } }


private void putLocalVersioned  ( SpaceMapEntry newEnvelope , Object key , Object value , CacheEntry cacheEntry ) { VersionCacheEntry versionEntry = new VersionCacheEntry ( newEnvelope . getVersion ( ) ) ; boolean replaced = _cache . replace ( key , versionEntry , cacheEntry ) ; if ( ! versionEntry . isChecked ( ) && _putFirst ) { if ( _cache . size ( ) >= _sizeLimit ) _evictionStrategy . evict ( this ) ; Object old = _cache . putIfAbsent ( key , cacheEntry ) ; if ( old != null ) { replaced = _cache . replace ( key , versionEntry , cacheEntry ) ; } } if ( replaced ) { Object entry = versionEntry . getOldEntry ( ) ; if ( ! ( entry instanceof DummyCacheEntry ) ) _evictionStrategy . discardEntry ( ( CacheEntry ) entry ) ; } }

Guardar valor de la versión en caché local


public static int [ ] shuffle  ( int [ ] intArray ) { if ( intArray == null ) { return null ; } return shuffle ( intArray , getRandom ( intArray . length ) ) ; }

Algoritmo que arrastra, le permita al azar la matriz Int especificada utilizando una fuente de aleatoriedad predeterminada


public S2LatLngRect ( final S2LatLng lo , final S2LatLng hi ) { lat = new R1Interval ( lo . lat ( ) . radians ( ) , hi . lat ( ) . radians ( ) ) ; lng = new S1Interval ( lo . lng ( ) . radians ( ) , hi . lng ( ) . radians ( ) ) ; }

Construya un rectángulo de latitudes mínimos y máximos y longitudes.Si lo.lng () & gt;hola.lng (), el rectángulo abarca la línea de longitud de 180 grados.


private boolean push  ( byte mode ) { ++ top ; if ( top >= stack . length ) { if ( top >= depth ) { return false ; } stack = Arrays . copyOf ( stack , Math . min ( stack . length * 2 , depth ) ) ; } stack [ top ] = mode ; return true ; }


public boolean equals  ( Object obj ) { return ReferentUuids . compare ( this , obj ) ; }

Los proxies para servidores con la misma ID de servicio se consideran iguales.


public void close  ( ) { if ( textStorageReader != null ) textStorageReader . closeAllFiles ( ) ; if ( dataIndexReader != null ) try { dataIndexReader . close ( ) ; } catch ( IOException e ) { Basic . caught ( e ) ; } }


public AudioSaveQuery hash  ( String value ) { return unsafeParam ( "hash" , value ) ; }

Este parámetro se devuelve cuando el archivo de audio se carga en el servidor.


public void advance  ( ) throws ConcurrentModificationException , NoSuchElementException  { if ( referenceCount != count ) { throw new ConcurrentModificationException ( ) ; } current = next ; try { while ( states [ ++ next ] != FULL ) { } } catch ( ArrayIndexOutOfBoundsException e ) { next = - 2 ; if ( current < 0 ) { throw new NoSuchElementException ( ) ; } } }


public void createContainerFromWidgets  ( ArrayList < ConstraintWidget > widgets , ConstraintWidgetContainer containerInstance , String name ) { Collections . sort ( widgets , null ) ; if ( widgets . size ( ) == 0 ) { return ; } for ( ConstraintWidget w : mWidgets . values ( ) ) { for ( ConstraintWidget widget : widgets ) { w . disconnectWidget ( widget ) ; widget . resetAnchors ( ) ; widget . setHorizontalBiasPercent ( 0.5f ) ; widget . setVerticalBiasPercent ( 0.5f ) ; } } WidgetContainer parent = ( WidgetContainer ) widgets . get ( 0 ) . getParent ( ) ; if ( parent == null ) { parent = mRoot ; } ConstraintWidgetContainer container = ConstraintWidgetContainer . createContainer ( containerInstance , name , widgets , 8 ) ; if ( container != null ) { if ( container . getCompanionWidget ( ) == null ) { container . setCompanionWidget ( WidgetCompanion . create ( container ) ) ; } parent . add ( container ) ; setWidget ( container ) ; boolean previousAnimationState = Animator . doAnimation ( ) ; Animator . setAnimationEnabled ( false ) ; mRoot . layout ( ) ; Animator . setAnimationEnabled ( previousAnimationState ) ; } }

Inserte una nueva restricciónWidgetContainer en su lugar, desde una lista de widgets.Los widgets se borrarán de sus restricciones actuales y se colocarán como hijos del nuevo contenedor.


void addRTypeResourceName  ( RType rType , String resourceName , String resourceValue , ResourceDirectory resourceDirectory ) { Map < String , Set < ResourceDirectory > > directoryResourceDirectoryMap = null ; if ( this . rTypeResourceDirectoryMap . containsKey ( rType ) ) { directoryResourceDirectoryMap = this . rTypeResourceDirectoryMap . get ( rType ) ; } else { directoryResourceDirectoryMap = new HashMap < String , Set < ResourceDirectory > > ( ) ; this . rTypeResourceDirectoryMap . put ( rType , directoryResourceDirectoryMap ) ; } Set < ResourceDirectory > resourceDirectorySet = null ; if ( directoryResourceDirectoryMap . containsKey ( resourceDirectory . directoryName ) ) { resourceDirectorySet = directoryResourceDirectoryMap . get ( resourceDirectory . directoryName ) ; } else { resourceDirectorySet = new HashSet < ResourceDirectory > ( ) ; directoryResourceDirectoryMap . put ( resourceDirectory . directoryName , resourceDirectorySet ) ; } boolean find = false ; ResourceDirectory newResourceDirectory = new ResourceDirectory ( resourceDirectory . directoryName , resourceDirectory . resourceFullFilename ) ; if ( ! resourceDirectorySet . contains ( newResourceDirectory ) ) { resourceDirectorySet . add ( newResourceDirectory ) ; } for ( ResourceDirectory oldResourceDirectory : resourceDirectorySet ) { if ( oldResourceDirectory . resourceEntrySet . contains ( new ResourceEntry ( resourceName , resourceValue ) ) ) { find = true ; String resourceKey = rType + "/" + resourceDirectory . directoryName + "/" + resourceName ; Set < String > fullFilenameSet = null ; if ( ! this . duplicateResourceMap . containsKey ( resourceKey ) ) { fullFilenameSet = new HashSet < String > ( ) ; fullFilenameSet . add ( oldResourceDirectory . resourceFullFilename ) ; this . duplicateResourceMap . put ( resourceKey , fullFilenameSet ) ; } else { fullFilenameSet = this . duplicateResourceMap . get ( resourceKey ) ; } fullFilenameSet . add ( resourceDirectory . resourceFullFilename ) ; } } if ( ! find ) { for ( ResourceDirectory oldResourceDirectory : resourceDirectorySet ) { if ( oldResourceDirectory . equals ( newResourceDirectory ) ) { if ( ! oldResourceDirectory . resourceEntrySet . contains ( new ResourceEntry ( resourceName , resourceValue ) ) ) { oldResourceDirectory . resourceEntrySet . add ( new ResourceEntry ( resourceName , resourceValue ) ) ; } } } } }


public int addAll  ( SplitSystem splits ) { int count = 0 ; for ( Iterator it = splits . iterator ( ) ; it . hasNext ( ) ; ) { Split split = ( Split ) it . next ( ) ; if ( ! split2index . keySet ( ) . contains ( split ) ) { addSplit ( split ) ; count ++ ; } } return count ; }

Agregue todas las divisiones dadas que aún no están presentes (como se dividen, ignorando las pesas, etc.)


public CommandManagerFX ( IDirector dir , IDirectableViewer viewer , String commandsPath ) { this ( dir , viewer , new String [ ] { commandsPath } , false ) ; }

construir un analizador y cargar todos los comandos encontrados para la ruta dada


public static float reduce  ( float startValue , float endValue , float time ) { if ( startValue < endValue ) throw new IllegalArgumentException ( "End size can't be larger than start size." ) ; return endValue + ( startValue - endValue ) * ( 1 - time ) ; }

Reducir el valor de StartValue a EndValue


public void onEnterZone  ( ZoneInstance zoneInstance ) { }

Será llamado por ZoneManager cuando la criatura ingrese a una zona específica


@ Override public long limit  ( ) { return fileLength >>> 2 ; }

Longitud de la matriz (longitud del archivo / 4)


private UByte ( long value ) throws NumberFormatException { this . value = rangeCheck ( value ) ; }


public static String nullSafeToString  ( float [ ] array ) { if ( array == null ) { return NULL_STRING ; } int length = array . length ; if ( length == 0 ) { return EMPTY_ARRAY ; } StringBuffer buffer = new StringBuffer ( ) ; for ( int i = 0 ; i < length ; i ++ ) { if ( i == 0 ) { buffer . append ( ARRAY_START ) ; } else { buffer . append ( ARRAY_ELEMENT_SEPARATOR ) ; } buffer . append ( array [ i ] ) ; } buffer . append ( ARRAY_END ) ; return buffer . toString ( ) ; }

Devuelva una representación de una cadena de los contenidos de la matriz especificada.La representación de la cadena consiste en una lista de los elementos de la matriz, encerrados en tirantes rizados (<código> "{}" </ código>).Los elementos adyacentes están separados por los caracteres <código> "," </ código> (una coma seguido de un espacio).Devuelve <código> "NULL" </ código> Si <code> Array </ code> es <code> null </ code>.


public PhotosGetAllQuery ( VkApiClient client , UserActor actor ) { super ( client , "photos.getAll" , GetAllResponse . class ) ; accessToken ( actor . getAccessToken ( ) ) ; }

Crea una instancia abstractQueryBuilder que se puede usar para construir una solicitud API con varios parámetros


protected Object resolve  ( ) { GigaSpace gs = findGigaSpaceByName ( this . name ) ; if ( GigaSpace . class . isAssignableFrom ( getMemberType ( ) ) ) { if ( ! getMemberType ( ) . isInstance ( gs ) ) { throw new IllegalArgumentException ( "Cannot inject " + this . member + " with GigaSpaces [" + this . name + "]: type mismatch" ) ; } return gs ; } else { throw new IllegalArgumentException ( "Failure to inject" ) ; } }

Resuelva el objeto contra el contexto de la aplicación.


public static void updateUserNamePictureCache  ( String accountId , String fullName , Bitmap bitmap ) { sChildAccountId = null ; sCachedBadgedPicture = null ; sToNamePicture . put ( accountId , new Pair < String , Bitmap > ( fullName , makeRoundUserPicture ( bitmap ) ) ) ; }

Actualiza el nombre de usuario y la imagen en el caché.


public static StateListDrawable toStateListDrawable  ( Drawable normal , Drawable pressed , Drawable focused , Drawable unable ) { StateListDrawable drawable = new StateListDrawable ( ) ; drawable . addState ( new int [ ] { android . R . attr . state_pressed , android . R . attr . state_enabled } , pressed ) ; drawable . addState ( new int [ ] { android . R . attr . state_enabled , android . R . attr . state_focused } , focused ) ; drawable . addState ( new int [ ] { android . R . attr . state_enabled } , normal ) ; drawable . addState ( new int [ ] { android . R . attr . state_focused } , focused ) ; drawable . addState ( new int [ ] { android . R . attr . state_window_focused } , unable ) ; drawable . addState ( new int [ ] { } , normal ) ; return drawable ; }

A la lista de estado Dublable Lista de estado Dibujable.


public M best  ( final G game , final IMoveGenerator < M , G > generator , int depthmax ) throws TimeoutException { try { this . depthmax = depthmax ; final MinMaxEvaluatedMove best = minimax ( game , generator , depthmax , Double . NEGATIVE_INFINITY , Double . POSITIVE_INFINITY , game . currentPlayer ( ) == 0 , killer ) ; killer = best ; return best . getMove ( ) ; } catch ( final AlphaBetaPrunningException e ) { throw new RuntimeException ( "evaluated move found with value not between + infinity and - infinity..." ) ; } }

Búsqueda en el árbol del juego El mejor movimiento usando Minimax con la poda Beta Alpha.


private void handleFieldInits  ( soot . SootMethod sootMethod ) { ArrayList < FieldDecl > fieldInits = ( ( soot . javaToJimple . PolyglotMethodSource ) sootMethod . getSource ( ) ) . getFieldInits ( ) ; if ( fieldInits != null ) { handleFieldInits ( fieldInits ) ; } }


@ Override public void actionPerformed  ( ActionEvent ev ) { execute ( "select what=previous;" ) ; }


static int findBestSampleSize  ( int actualWidth , int actualHeight , int desiredWidth , int desiredHeight ) { double wr = ( double ) actualWidth / desiredWidth ; double hr = ( double ) actualHeight / desiredHeight ; double ratio = Math . min ( wr , hr ) ; float n = 1.0f ; while ( ( n * 2 ) <= ratio ) { n *= 2 ; } return ( int ) n ; }

Devuelve el mayor divisor de potencia de dos para su uso en la escalada de un mapa de bits que no resultará en la escala de las dimensiones deseadas.


private static int [ ] compileLowerIndirection  ( final int parameters , final int order , final DSCompiler valueCompiler , final DSCompiler derivativeCompiler ) { if ( parameters == 0 || order <= 1 ) { return new int [ ] { 0 } ; } final int vSize = valueCompiler . lowerIndirection . length ; final int dSize = derivativeCompiler . lowerIndirection . length ; final int [ ] lowerIndirection = new int [ vSize + dSize ] ; System . arraycopy ( valueCompiler . lowerIndirection , 0 , lowerIndirection , 0 , vSize ) ; for ( int i = 0 ; i < dSize ; ++ i ) { lowerIndirection [ vSize + i ] = valueCompiler . getSize ( ) + derivativeCompiler . lowerIndirection [ i ] ; } return lowerIndirection ; }

Compilar la matriz de indirección de derivados inferiores.<P> Esta matriz de indirección contiene los índices de todos los elementos, excepto los derivados para la última orden de derivación.</ p>


@ Override public void write  ( String str , int st , int end ) throws IOException { out . write ( str , st , end ) ; }

Escriba los caracteres especificados de una cadena.


@ Override public void populateField  ( String key ) { if ( comboBox != null ) { comboBox . setSelectedDataKey ( key ) ; } }


private int parseStyleInDefaultWorkspace  ( GeoServerRESTReader reader , int count , List < StyleWrapper > styleList ) { RESTStyleList geoServerStyleList = reader . getStyles ( ) ; for ( String style : geoServerStyleList . getNames ( ) ) { StyleWrapper newStyleWrapper = new StyleWrapper ( DEFAULT_WORKSPACE_NAME , style ) ; styleList . add ( newStyleWrapper ) ; if ( parentObj != null ) { parentObj . readStylesProgress ( connection , count , count ) ; } count ++ ; } return count ; }

Analiza el estilo en el espacio de trabajo predeterminado.


public static boolean isCategoryTop  ( Delegator delegator , LocalDispatcher dispatcher , String productCategoryId ) { if ( UtilValidate . isEmpty ( productCategoryId ) ) { return false ; } try { List < EntityCondition > rolllupConds = FastList . newInstance ( ) ; rolllupConds . add ( EntityCondition . makeCondition ( "productCategoryId" , productCategoryId ) ) ; rolllupConds . add ( EntityUtil . getFilterByDateExpr ( ) ) ; Collection < GenericValue > rollups = EntityQuery . use ( delegator ) . from ( "ProductCategoryRollup" ) . where ( rolllupConds ) . cache ( ) . queryList ( ) ; return rollups . isEmpty ( ) ; } catch ( GenericEntityException e ) { Debug . logWarning ( e , module ) ; } return false ; }

Scipio: devuelve verdadero solo si la categoría ID es una categoría superior.<p> Nota: es el almacenamiento en caché


public MalformedURIException ( String p_msg ) { super ( p_msg ) ; }

Construye un <código> malformeduriexception </ code> con el mensaje de detalle especificado.


@ Override public synchronized void clear  ( ) { File [ ] files = mRootDirectory . listFiles ( ) ; if ( files != null ) { for ( File file : files ) { file . delete ( ) ; } } mEntries . clear ( ) ; mTotalSize = 0 ; VolleyLog . d ( "Cache cleared." ) ; }

Borra el caché.Elimina todos los archivos en caché desde el disco.


public void putCommandRunner  ( final long equipmentId , final ICommandRunner commandRunner ) { commandRunners . put ( equipmentId , commandRunner ) ; }

Pone un corredor de comandos a este controlador.


public void afterMemberRemoved  ( MemberRemovedEvent memberRemovedEvent ) { }

Llamado después de que se elimine el miembro objetivo


public static final MediaFormat createVideoFormat  ( String mime , int width , int height ) { MediaFormat format = new MediaFormat ( ) ; format . setString ( KEY_MIME , mime ) ; format . setInteger ( KEY_WIDTH , width ) ; format . setInteger ( KEY_HEIGHT , height ) ; return format ; }


protected void doOptimizedEval  ( final Semaphore sSem , PrintStream pOverallResultsOutStream , int WordNGramSize_Min , int WordNGramSize_Max , int Word_Dmax , int CharacterNGramSize_Min , int CharacterNGramSize_Max , int Character_Dmax , boolean bDoCharNGrams , boolean bDoWordNGrams , String sSummaryDir , String sModelDir , int iThreads , boolean bSilent , boolean bProgress ) { if ( pOverallResultsOutStream == null ) pOverallResultsOutStream = System . out ; ThreadList tqRobin = new ThreadList ( iThreads ) ; DocumentSet dsSummarySet = new DocumentSet ( sSummaryDir , 1.0 ) ; final DocumentSet dsModelSet = new DocumentSet ( sModelDir , 1.0 ) ; dsSummarySet . createSets ( ) ; dsModelSet . createSets ( ) ; HashMap hmCategoryResults = new HashMap ( ) ; if ( dsSummarySet . getTrainingSet ( ) . size ( ) * dsModelSet . getTrainingSet ( ) . size ( ) == 0 ) { System . err . println ( "Empty document set..." ) ; System . exit ( - 1 ) ; } pOverallResultsOutStream . print ( "Theme\t" ) ; pOverallResultsOutStream . print ( "SystemID\t" ) ; if ( bDoWordNGrams ) { pOverallResultsOutStream . print ( "GraphCooccurence\t" ) ; pOverallResultsOutStream . print ( "GraphValue\t" ) ; pOverallResultsOutStream . print ( "GraphSize\t" ) ; pOverallResultsOutStream . print ( "HistoContainmentSimilarity\t" ) ; pOverallResultsOutStream . print ( "HistoValue\t" ) ; pOverallResultsOutStream . print ( "HistoSize\t" ) ; pOverallResultsOutStream . print ( "OverallSimil\t" ) ; } if ( bDoCharNGrams ) { pOverallResultsOutStream . print ( "CharGraphCooccurence\t" ) ; pOverallResultsOutStream . print ( "CharGraphValue\t" ) ; pOverallResultsOutStream . print ( "CharGraphSize\t" ) ; pOverallResultsOutStream . print ( "NHistoContainmentSimilarity\t" ) ; pOverallResultsOutStream . print ( "NHistoValue\t" ) ; pOverallResultsOutStream . print ( "NHistoSize\t" ) ; pOverallResultsOutStream . print ( "NOverallSimil\t" ) ; } pOverallResultsOutStream . println ( ) ; int iTotal = dsSummarySet . getTrainingSet ( ) . size ( ) ; int iCur = 0 ; Iterator iCatIter = dsModelSet . getCategories ( ) . iterator ( ) ; Date dStart = new Date ( ) ; while ( iCatIter . hasNext ( ) ) { String sCurCategory = ( String ) iCatIter . next ( ) ; if ( ! bSilent ) System . err . println ( "Processing category:" + sCurCategory ) ; hModelCache . clear ( ) ; hNModelCache . clear ( ) ; List lModelFiles = dsModelSet . getFilesFromCategory ( sCurCategory ) ; Iterator iIter = dsSummarySet . getFilesFromCategory ( sCurCategory , dsSummarySet . FROM_TRAINING_SET ) . iterator ( ) ; while ( iIter . hasNext ( ) ) { final CategorizedFileEntry cfeCur = ( CategorizedFileEntry ) iIter . next ( ) ; Runnable r = new GaussCalcSimilRunner ( WordNGramSize_Min , WordNGramSize_Max , Word_Dmax , CharacterNGramSize_Min , CharacterNGramSize_Max , Character_Dmax , cfeCur , lModelFiles , sSem , bDoCharNGrams , bDoWordNGrams , pOverallResultsOutStream , bSilent , this , WeightMethod , Progress ) ; while ( ! tqRobin . addThreadFor ( r ) ) Thread . yield ( ) ; Date dCurTime = new Date ( ) ; long lRemaining = ( iTotal - iCur + 1 ) * ( long ) ( ( double ) ( dCurTime . getTime ( ) - dStart . getTime ( ) ) / iCur ) ; if ( ! bSilent || ( bProgress ) ) System . err . print ( "Completed " + String . format ( "%7.4f" , ( double ) iCur ++ / iTotal * 100 ) + "%" + String . format ( " - Remaining %50s\r" , gr . demokritos . iit . jinsect . utils . millisToMinSecString ( lRemaining ) ) ) ; } } try { tqRobin . waitUntilCompletion ( ) ; } catch ( InterruptedException ex ) { System . err . println ( "Could not complete execution of all tasks." ) ; ex . printStackTrace ( System . err ) ; } System . err . println ( "Completed 100%. A total of " + iTotal + " comparisons were " + "performed." ) ; }

Realiza una evaluación optimizada de un conjunto dado de resúmenes, dado un directorio modelo.


public void recordOpenedTabSwitcher  ( ) { setFirstAction ( OPENED_TAB_SWITCHER ) ; }

Registra que se ha accedido al conmutador de la pestaña.


public GroupsGetMembersQueryWithFields groupId  ( String value ) { return unsafeParam ( "group_id" , value ) ; }

ID o nombre de pantalla de la comunidad.


@ Override public String toString  ( ) { return String . format ( "Segment[%s%smin=%s;size=%,d;bytes=%,d;added=%,d;deleted=%,d;id=%s;dataId=%s]" , _deleted ? "DELETED;" : "" , _splitting ? "SPLITTING;" : "" , ( _min != null ) ? ByteBufferUtil . bytesToHex ( _min ) : null , cardinality ( ) , segmentSize ( ) , _adds , _deletes , _id . toString ( ) . substring ( 4 , 8 ) , _dataId . toString ( ) . substring ( 4 , 8 ) ) ; }


private static String joinPath  ( String path1 , String path2 ) { File file1 = new File ( path1 ) ; File file2 = new File ( file1 , path2 ) ; return file2 . getPath ( ) ; }


public QueryAndID takeNextQuery  ( ) throws IOException  { nextQuery : while ( true ) { QueryAndID theQuery = null ; synchronized ( this ) { for ( QueryAndID query : queryQueue . values ( ) ) { if ( query . state == 0 && globalState . hasIndex ( query . indexName , query . shardOrd ) ) { theQuery = query ; query . state = 2 ; break ; } } if ( theQuery == null ) { try { wait ( ) ; } catch ( InterruptedException ie ) { Thread . currentThread ( ) . interrupt ( ) ; throw new RuntimeException ( ie ) ; } continue ; } } for ( RemoteNodeConnection node : globalState . remoteNodes ) { synchronized ( node . c ) { node . c . out . writeByte ( NodeToNodeHandler . CMD_TAKE_QUERY ) ; node . c . out . writeBytes ( theQuery . id . id , 0 , theQuery . id . id . length ) ; node . c . bos . flush ( ) ; byte result = node . c . in . readByte ( ) ; if ( result == 0 ) { continue nextQuery ; } } } return theQuery ; } }

Coloque la siguiente consulta para correr desde la cola de consulta distribuida, esperando si la cola está vacía.


@ SuppressLint ( "NewApi" ) public final void makeFullScreenAfterKitKat  ( boolean enable ) { try { View decorView = getWindow ( ) . getDecorView ( ) ; if ( enable ) { int uiOptionsEnable = View . SYSTEM_UI_FLAG_LAYOUT_STABLE | View . SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION | View . SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN | View . SYSTEM_UI_FLAG_HIDE_NAVIGATION | View . SYSTEM_UI_FLAG_FULLSCREEN | View . SYSTEM_UI_FLAG_IMMERSIVE_STICKY ; decorView . setSystemUiVisibility ( uiOptionsEnable ) ; } else { int uiOptionsDisable = View . SYSTEM_UI_FLAG_LAYOUT_STABLE | View . SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION | View . SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN | View . SYSTEM_UI_FLAG_IMMERSIVE_STICKY ; decorView . setSystemUiVisibility ( uiOptionsDisable ) ; } } catch ( Exception e ) { WindowManager . LayoutParams lp = getWindow ( ) . getAttributes ( ) ; if ( enable ) { lp . flags |= WindowManager . LayoutParams . FLAG_FULLSCREEN | View . SYSTEM_UI_FLAG_IMMERSIVE_STICKY ; } else { lp . flags &= ( ~ WindowManager . LayoutParams . FLAG_FULLSCREEN | View . SYSTEM_UI_FLAG_IMMERSIVE_STICKY ) ; } getWindow ( ) . setAttributes ( lp ) ; } }

Si la versión de Android es más alta que Kitkat (API> = 19). Utilice esta llamada para mostrar y esconder


public Index open  ( Transaction tx ) { TableInfo ti = VanillaDb . catalogMgr ( ) . getTableInfo ( tblName , tx ) ; if ( ti == null ) throw new TableNotFoundException ( "table '" + tblName + "' is not defined in catalog." ) ; return Index . newInstance ( this , ti . schema ( ) . type ( fldName ) , tx ) ; }

Abre el índice descrito por este objeto.


private String textAreaHas  ( final int numOfLines ) { return "textArea has " + numOfLines + " lines" ; }

Método de ayudante para afirmar la razón.


public static void buildAchievementStats  ( JsonObject json , EntityPlayerMP player ) { StatFileWriter sfw = player . getStatFile ( ) ; json . addProperty ( "DistanceTravelled" , sfw . readStat ( ( StatBase ) StatList . distanceWalkedStat ) + sfw . readStat ( ( StatBase ) StatList . distanceSwumStat ) + sfw . readStat ( ( StatBase ) StatList . distanceDoveStat ) + sfw . readStat ( ( StatBase ) StatList . distanceFallenStat ) ) ; json . addProperty ( "TimeAlive" , sfw . readStat ( ( StatBase ) StatList . timeSinceDeathStat ) ) ; json . addProperty ( "MobsKilled" , sfw . readStat ( ( StatBase ) StatList . mobKillsStat ) ) ; json . addProperty ( "DamageTaken" , sfw . readStat ( ( StatBase ) StatList . damageTakenStat ) ) ; }

Construye los datos del mundo de logros básicos que se utilizarán como señales de observación del oyente.


public boolean enabled  ( ) { return soot . PhaseOptions . getBoolean ( options , "enabled" ) ; }


public FinderException ( ) { super ( ) ; }

Construye una <código> FinderException </ Code> con <Code> Null </ Code> como su mensaje de detalle de error.


public Vector3f divideLocal  ( Vector3f scalar ) { x /= scalar . x ; y /= scalar . y ; z /= scalar . z ; return this ; }

<CÓDIGO> DIVENTOCAL </ CODE> Divide este vector por un escalar internamente y devuelve un asa a este vector para una fácil encadenamiento de llamadas.Dividir por cero resultará en una excepción.


public void loadData  ( Table t , String query , Object lock ) { loadData ( t , query , null , lock , null ) ; }

Ejecuta asíncronamente una consulta y almacena los resultados en la instancia de la tabla dada.Todo el procesamiento de datos se realiza en un hilo de ejecución separado.


public MultiwayPoolBuilder < K , R > expireAfterWrite  ( long duration , TimeUnit unit ) { checkState ( expireAfterWriteNanos == UNSET_INT , "expireAfterWrite was already set to %s ns" , expireAfterWriteNanos ) ; checkArgument ( duration >= 0 , "duration cannot be negative: %s %s" , duration , unit ) ; expireAfterWriteNanos = unit . toNanos ( duration ) ; return this ; }

Especifica que cada recurso debe eliminarse automáticamente del grupo una vez que haya transcurrido una duración fija después de la creación del recurso.


@ RequestMapping ( value = ClientUris . CONFIG_FETCHES , method = RequestMethod . GET ) public List < ConfigItem > fetches  ( @ RequestParam ( "names" ) String names ) { ClientSession client = ClientContext . get ( ) ; assert client != null ; List < String > nameList = Splitters . COMMA . splitToList ( names ) ; Response < List < Config > > configsResp = configService . findByNames ( client . getAppId ( ) , nameList ) ; if ( ! configsResp . isSuccess ( ) ) { Logs . error ( "failed to fetch configs(names={}), cause: {}" , names , configsResp . getErr ( ) ) ; return Collections . emptyList ( ) ; } return ConfigItemFactory . creates ( configsResp . getData ( ) ) ; }


public void shutDown  ( ) { setTab ( null ) ; if ( mLayerTitleCache != null ) mLayerTitleCache . shutDown ( ) ; mCompositorView . shutDown ( ) ; }

Debe solicitado la limpieza cuando la instancia de CompositorView ya no se usa.


public SaveHeaderGroup copy  ( ) { SaveHeaderGroup clone = new SaveHeaderGroup ( ) ; clone . headers . addAll ( this . headers ) ; return clone ; }


public D addFunction  ( PathEdge < N , D > edge ) { return nonEmptyReverseLookup . putIfAbsent ( edge , edge . factAtTarget ( ) ) ; }

Registra una función de salto.La declaración de origen está implícita.


public int length  ( ) { return this . myArrayList . size ( ) ; }

Obtenga la cantidad de elementos en el JSONARRAY, incluidos los nulos.


private void recycleView  ( View view , int index ) { int count = wheel . getViewAdapter ( ) . getItemsCount ( ) ; if ( ( index < 0 || index >= count ) && ! wheel . isCyclic ( ) ) { emptyItems = addView ( view , emptyItems ) ; } else { while ( index < 0 ) { index = count + index ; } index %= count ; items = addView ( view , items ) ; } }

Agrega vista al caché.Determina el tipo de vista (vista del elemento o vacío) por índice.


public boolean isIgnorableWhitespace  ( ) { if ( needsSyncData ( ) ) { synchronizeData ( ) ; } return internalIsIgnorableWhitespace ( ) ; }

No DOM: devuelve si este texto es el espacio en blanco ignorable.


@ Override public boolean isAlreadyMatched  ( ) { return false ; }

¿La entrada que se devuelve ya coincida con la plantilla de búsqueda actualmente es verdadera si la exploración subyacente hecha por Cachemanager :: Entristioner


public int addAdjustment  ( GenericValue adjustment ) { adjustments . add ( adjustment ) ; return adjustments . indexOf ( adjustment ) ; }

Añadir un ajuste al pedido;No se preocupe por configurar el ordenido, OrderEtemseqid o OrderAdJustmentst;Se establecerán cuando se crea el pedido.


public static void writeResultFile  ( File file , Map < String , List < QueryResponseJSON > > resultMap ) throws IOException { try ( BufferedWriter bw = new BufferedWriter ( new FileWriter ( file ) ) ) { for ( Entry < String , List < QueryResponseJSON > > entry : resultMap . entrySet ( ) ) { for ( QueryResponseJSON hitJSON : entry . getValue ( ) ) { bw . write ( hitJSON . getJSONString ( ) ) ; bw . newLine ( ) ; } } } }

Escribe elementos del resumen en el archivo de salida, una línea para cada elemento, donde cada línea es una representación de cadena del objeto QueryResponseJson correspondiente


public void initialize  ( Vector2 [ ] points ) { int size = points . length ; DoubleEdgeListFace face = new DoubleEdgeListFace ( ) ; this . faces . add ( face ) ; DoubleEdgeListHalfEdge prevLeftEdge = null ; DoubleEdgeListHalfEdge prevRightEdge = null ; for ( int i = 0 ; i < size ; i ++ ) { Vector2 point = points [ i ] ; DoubleEdgeListVertex vertex = new DoubleEdgeListVertex ( point ) ; DoubleEdgeListHalfEdge left = new DoubleEdgeListHalfEdge ( ) ; DoubleEdgeListHalfEdge right = new DoubleEdgeListHalfEdge ( ) ; left . face = face ; left . next = null ; left . origin = vertex ; left . twin = right ; right . face = null ; right . next = prevRightEdge ; right . origin = null ; right . twin = left ; this . edges . add ( left ) ; this . edges . add ( right ) ; vertex . leaving = left ; this . vertices . add ( vertex ) ; if ( prevLeftEdge != null ) { prevLeftEdge . next = left ; } if ( prevRightEdge != null ) { prevRightEdge . origin = vertex ; } prevLeftEdge = left ; prevRightEdge = right ; } DoubleEdgeListHalfEdge firstLeftEdge = this . edges . get ( 0 ) ; prevLeftEdge . next = firstLeftEdge ; DoubleEdgeListHalfEdge firstRightEdge = this . edges . get ( 1 ) ; firstRightEdge . next = prevRightEdge ; prevRightEdge . origin = this . vertices . get ( 0 ) ; face . edge = firstLeftEdge ; }

Inicializa la clase DCEL dada los puntos del polígono.


public boolean remove  ( JsonElement element ) { return elements . remove ( element ) ; }

Elimina la primera aparición del elemento especificado de esta matriz, si está presente.Si la matriz no contiene el elemento, no se modifica.


public static SM_SYSTEM_MESSAGE STR_SKILL_TOGGLE_SKILL_TURNED_ON  ( String value0 ) { return new SM_SYSTEM_MESSAGE ( 1390121 , value0 ) ; }


public boolean isEmpty  ( ) { return this . results == null || this . results . isEmpty ( ) ; }

Obtiene si este objeto de resultado está vacío, es decir, no contiene flujos de información


public Label ( String tag ) { id = tag . intern ( ) ; opc = opc_label ; operand = null ; }

Crea una nueva etiqueta con esta etiqueta.Cualquier etiqueta con esta etiqueta será tratada como idéntica a esta.Puedes reutilizar las etiquetas si quieres


public T dotProduct  ( ArrayFieldVector < T > v ) throws MathIllegalArgumentException  { checkVectorDimensions ( v . data . length ) ; T dot = field . getZero ( ) ; for ( int i = 0 ; i < data . length ; i ++ ) { dot = dot . add ( data [ i ] . multiply ( v . data [ i ] ) ) ; } return dot ; }


public boolean isMinIsZero  ( ) { return minIsZero ; }


public static ICacheSystem create  ( Configuration conf ) { String server = conf . getString ( "cache.url" ) . substring ( Cache . REDIS . length ( ) ) ; String [ ] ss = server . split ( ":" ) ; String host = ss [ 0 ] ; int port = 6379 ; if ( ss . length > 1 ) { port = X . toInt ( ss [ 1 ] , 0 ) ; } RedisCache r = new RedisCache ( ) ; JedisPoolConfig config = new JedisPoolConfig ( ) ; config . setMaxTotal ( 20 ) ; config . setMaxIdle ( 5 ) ; config . setMaxWaitMillis ( 1000l ) ; config . setTestOnBorrow ( false ) ; List < JedisShardInfo > shards = new ArrayList < JedisShardInfo > ( ) ; shards . add ( new JedisShardInfo ( host , port , "master" ) ) ; r . shardedJedisPool = new ShardedJedisPool ( config , shards ) ; r . jedis = r . shardedJedisPool . getResource ( ) ; return r ; }


public static String toTree  ( @ NotNull List < NlComponent > roots ) { return toTree ( roots , false ) ; }

Vuelca el árbol de componentes, recursivamente


public FieldVector3D < T > subtract  ( final T factor , final Vector3D v ) { return new FieldVector3D < T > ( x . subtract ( factor . multiply ( v . getX ( ) ) ) , y . subtract ( factor . multiply ( v . getY ( ) ) ) , z . subtract ( factor . multiply ( v . getZ ( ) ) ) ) ; }

Restar un vector escalado de la instancia.


public void scheduleValueForSending  ( ) { this . sendValue = true ; }

Informa al programador, esa la próxima vez que se despierta, debe enviar el valor de la etiqueta de datos de origen


public void uploadNewFile  ( Context context , Account account , String localPath , String remotePath , int behaviour , String mimeType , boolean createRemoteFile , int createdBy ) { uploadNewFile ( context , account , new String [ ] { localPath } , new String [ ] { remotePath } , new String [ ] { mimeType } , behaviour , createRemoteFile , createdBy ) ; }

Llame para cargar un nuevo archivo individual


public OutOfRangeException ( Localizable specific , Number wrong , Number lo , Number hi ) { super ( specific , wrong , lo , hi ) ; this . lo = lo ; this . hi = hi ; }

Construya una excepción de las dimensiones no coincidentes con una información de contexto específica.


private static TestingServer startLocalZooKeeper  ( ) throws Exception  { ( ( Logger ) LoggerFactory . getLogger ( "org.apache.zookeeper" ) ) . setLevel ( Level . ERROR ) ; TestingServer zooKeeperServer = new TestingServer ( 2181 ) ; System . setProperty ( "dw.zooKeeper.connectString" , zooKeeperServer . getConnectString ( ) ) ; return zooKeeperServer ; }

Inicie una copia en memoria de ZOOKEEPER.


private void scheduleRepeatingAlarm  ( ) { Intent registerIntent = createRegisterRequestIntent ( this ) ; PendingIntent pIntent = PendingIntent . getService ( this , 0 , registerIntent , 0 ) ; AlarmManager am = ( AlarmManager ) getSystemService ( Context . ALARM_SERVICE ) ; setAlarm ( am , pIntent , AlarmManager . RTC , mTimestampForNewRequest ) ; }

Establece una alarma de repetición que incendia la solicitud de intentos de registro.Configuración de la alarma sobrescribe cualquier alarma ya está allí, y reinicie los borrar las alarmas que se configuren actualmente.


@ TargetApi ( Build . VERSION_CODES . LOLLIPOP ) private boolean isRestartNeeded  ( boolean optOut ) { if ( optOut ) return true ; boolean isFromFre = getActivity ( ) . getIntent ( ) != null && getActivity ( ) . getIntent ( ) . getBooleanExtra ( IntentHandler . EXTRA_INVOKED_FROM_FRE , false ) ; if ( ! isFromFre ) return true ; ActivityManager am = ( ActivityManager ) getActivity ( ) . getSystemService ( Context . ACTIVITY_SERVICE ) ; PackageManager pm = getActivity ( ) . getPackageManager ( ) ; List < AppTask > taskList = am . getAppTasks ( ) ; for ( int i = 0 ; i < taskList . size ( ) ; i ++ ) { String className = DocumentUtils . getTaskClassName ( taskList . get ( i ) , pm ) ; if ( className == null ) continue ; if ( DocumentActivity . isDocumentActivity ( className ) ) return true ; } return false ; }

Averigua si necesitamos reiniciar la solicitud después de completar la migración de la pestaña.No necesitamos reiniciar si se está accediendo a esto desde Fre y no se han creado actividades de documentos.


private void enableHistoryMode  ( ) { historyCache . clear ( ) ; ClientDataTagImpl liveTag = null ; ClientDataTagImpl historyTag = null ; Collection < BaseListener > listeners = null ; for ( Entry < Long , ClientDataTagImpl > entry : liveCache . entrySet ( ) ) { liveTag = entry . getValue ( ) ; historyTag = liveTag . clone ( ) ; listeners = liveTag . getUpdateListeners ( ) ; liveTag . removeAllUpdateListeners ( ) ; historyTag . addUpdateListeners ( listeners ) ; historyCache . put ( entry . getKey ( ) , historyTag ) ; } activeCache = historyCache ; }

Método interno que clones todo el caché en vivo y mueve todos los <código> DataTagupdatelistedor </ Code> a las escuchas a la instancia de la memoria caché de historial.


public RegulaFalsiSolver ( final double relativeAccuracy , final double absoluteAccuracy , final double functionValueAccuracy ) { super ( relativeAccuracy , absoluteAccuracy , functionValueAccuracy , Method . REGULA_FALSI ) ; }


private DownloadManager ( ) { mDownloaderMap = new LinkedHashMap < String , Downloader > ( ) ; }


public RemExpr newRemExpr  ( Value op1 , Value op2 ) { return new JRemExpr ( op1 , op2 ) ; }

Construye un trozo de gramática remexpr (inmediato, inmediato).


Instantánea un nuevo ordenado por tiempo.


public static boolean isInited  ( ) { return inited ; }


public static Set < String > convertArrayToSet  ( String [ ] array ) { Set < String > resultSet = new HashSet < String > ( array . length ) ; Collections . addAll ( resultSet , array ) ; return resultSet ; }

Transforma la matriz de objetos de cuerdas para establecer


public String normalizeText  ( String text ) { return text . replaceAll ( "\\t" , "    " ) . replaceAll ( "[^\\S\\n]+(\\n)" , "$1" ) . replaceAll ( "[^\\S\\n]" , " " ) ; }

Normaliza el texto eliminando todos los espacios finales y la conversión de pestañas a los espacios.<p> Por lo general, esto se puede hacer una vez al principio del documento y nunca volver a preocuparse por ello.


Segment ( UUID id , Snapshot snapshot , long splitThresholdBytes , SplitQueue < Segment > splitQueue )  { if ( snapshot . version > PERSISTENCE_VERSION ) { throw new UnsupportedOperationException ( "Unsupported persistent sorted queue data version: " + snapshot . version ) ; } _id = checkNotNull ( id , "id" ) ; _dataId = Objects . firstNonNull ( snapshot . dataId , id ) ; _min = ( snapshot . min != null ) ? ByteBufferUtil . hexToBytes ( snapshot . min ) : null ; _adds = snapshot . adds ; _bytesAdded = snapshot . bytesAdded ; try { _distinctAdds = HyperLogLog . Builder . build ( checkNotNull ( snapshot . distinctAddsHll , "distinctAddsHll" ) ) ; } catch ( IOException e ) { throw Throwables . propagate ( e ) ; } _deletes = snapshot . deletes ; _bytesUntilSplitCheckSize = snapshot . bytesUntilSplitCheckSize ; _bytesUntilSplitCheckRemaining = 0 ; _splitThresholdBytes = splitThresholdBytes ; _splitting = snapshot . splitting ; _splitTargetSize = snapshot . splitTargetSize ; _splitTargetRemaining = snapshot . splitTargetRemaining ; _splitQueue = checkNotNull ( splitQueue , "splitQueue" ) ; }

Carga un segmento de una instantánea persistente.


public ColourRampPanel ( XMLTwoColourRampList xmlTwoColourRampList ) { this . rampDataList = createColourRampList ( xmlTwoColourRampList ) ; createUI ( ) ; }

Instantánea un nuevo panel de rampa de color.


private void messageArrived  ( GSMessageImpl message ) { if ( _logger . isLoggable ( Level . FINEST ) ) { _logger . log ( Level . FINEST , toString2 ( ) + "messageArrived(): " + message . JMSMessageID ) ; } synchronized ( synchTopicNotifyLock ) { while ( currentMessage != null ) { if ( _logger . isLoggable ( Level . FINEST ) ) { _logger . log ( Level . FINEST , toString2 ( ) + "messageArrived(): A message is already pending: " + currentMessage . JMSMessageID ) ; } try { synchTopicNotifyLock . wait ( ) ; } catch ( InterruptedException e ) { if ( m_session . isLocalConsumer ( m_consumerID ) ) { if ( _logger . isLoggable ( Level . SEVERE ) ) { _logger . log ( Level . SEVERE , toString2 ( ) + "messageArrived(): The notification thread was interrupted. Notification message: " + message . JMSMessageID ) ; } } else { if ( _logger . isLoggable ( Level . INFO ) ) { _logger . log ( Level . INFO , toString2 ( ) + "messageArrived(): The notification thread is exiting. Notification message: " + message . JMSMessageID ) ; } } } } currentMessage = message ; synchTopicNotifyLock . notify ( ) ; while ( ! m_closed && currentMessage != null ) { try { synchTopicNotifyLock . wait ( ) ; } catch ( InterruptedException e ) { if ( m_session . isLocalConsumer ( m_consumerID ) ) { if ( _logger . isLoggable ( Level . SEVERE ) ) { _logger . log ( Level . SEVERE , toString2 ( ) + "messageArrived(): The notification thread was interrupted while waiting to be released: " + currentMessage . JMSMessageID ) ; } } else { if ( _logger . isLoggable ( Level . INFO ) ) { _logger . log ( Level . INFO , toString2 ( ) + "messageArrived(): The notification thread is exiting. The consumer is closed. Pending message: " + currentMessage . JMSMessageID ) ; } } } } } }

Haga que el siguiente mensaje llegado esté disponible para el tema del consumidor.El hilo espera hasta que se tome el mensaje.


@ Override public void serializeAsField  ( Object bean , JsonGenerator jgen , SerializerProvider prov ) throws Exception { Object value = get ( bean ) ; if ( value == null ) { return ; } JsonSerializer < Object > ser = _serializer ; if ( ser == null ) { Class < ? > cls = value . getClass ( ) ; PropertySerializerMap map = _dynamicSerializers ; ser = map . serializerFor ( cls ) ; if ( ser == null ) { ser = _findAndAddDynamic ( map , cls , prov ) ; } } if ( _suppressableValue != null ) { if ( MARKER_FOR_EMPTY == _suppressableValue ) { if ( ser . isEmpty ( value ) ) { return ; } } else if ( _suppressableValue . equals ( value ) ) { return ; } } if ( value == bean ) { _handleSelfReference ( bean , ser ) ; } jgen . writeFieldName ( _name ) ; if ( _typeSerializer == null ) { ser . serialize ( value , jgen , prov ) ; } else { ser . serializeWithType ( value , jgen , prov , _typeSerializer ) ; } }

Método llamado para acceder a la propiedad que este frijol representa, desde dentro de la frijol, y para serializarlo como un campo de objeto JSON usando el serializador apropiado.


public void addTypeArgument  ( Access node ) { List < Access > list = ( parent == null || state == null ) ? getTypeArgumentListNoTransform ( ) : getTypeArgumentList ( ) ; list . addChild ( node ) ; }

Anexar un elemento a la lista de typeargument.


public void write  ( DataOutput raf ) throws IOException { assert duration >= 0 ; if ( data == null ) { throw new IllegalStateException ( "This method can only be called for data that is not null" ) ; } raf . writeLong ( duration ) ; raf . writeInt ( data . length ) ; raf . write ( data ) ; }

Escriba este datagrama a un archivo de acceso aleatorio o un flujo de salida de datos.Solo debe llamarse si los datos no son nulos.


public void removeChangingListener  ( OnWheelChangedListener listener ) { changingListeners . remove ( listener ) ; }


public static boolean dateTimeIsValid  ( final String dateTimeString ) { try { DATE_TIME_FORMAT . parseDateTime ( dateTimeString ) ; return true ; } catch ( IllegalArgumentException ex ) { return false ; } }

Este método comprueba si la cadena DateTimeRestring es un DateTime válido después del formato "YYAY-MM-DD".


@ Override public int compareTo  ( ValidationResult other ) { int result = orgUnit . getName ( ) . compareTo ( other . orgUnit . getName ( ) ) ; if ( result != 0 ) { return result ; } result = period . getStartDate ( ) . compareTo ( other . period . getStartDate ( ) ) ; if ( result != 0 ) { return result ; } result = period . getEndDate ( ) . compareTo ( other . period . getEndDate ( ) ) ; if ( result != 0 ) { return result ; } result = attributeOptionCombo . getId ( ) - other . attributeOptionCombo . getId ( ) ; if ( result != 0 ) { return result ; } result = validationImportanceOrder ( validationRule . getImportance ( ) ) - validationImportanceOrder ( other . validationRule . getImportance ( ) ) ; if ( result != 0 ) { return result ; } result = validationRule . getLeftSide ( ) . getDescription ( ) . compareTo ( other . validationRule . getLeftSide ( ) . getDescription ( ) ) ; if ( result != 0 ) { return result ; } result = validationRule . getOperator ( ) . compareTo ( other . validationRule . getOperator ( ) ) ; if ( result != 0 ) { return result ; } result = validationRule . getRightSide ( ) . getDescription ( ) . compareTo ( other . validationRule . getRightSide ( ) . getDescription ( ) ) ; if ( result != 0 ) { return result ; } result = ( int ) Math . signum ( Math . round ( 100.0 * leftsideValue ) - Math . round ( 100.0 * other . leftsideValue ) ) ; if ( result != 0 ) { return result ; } result = ( int ) Math . signum ( Math . round ( 100.0 * rightsideValue ) - Math . round ( 100.0 * other . rightsideValue ) ) ; if ( result != 0 ) { return result ; } return 0 ; }

Nota: Este método se llama de hilos en los que puede no ser posible inicializar las propiedades perezosas de hibernación.Así que las propiedades del objeto para comparar deben ser elegidas en consecuencia.


boolean insertSubtree  ( BinarySearchTreeNode < E > node ) { if ( node == null ) return false ; Iterator < E > iterator = new BinarySearchTreeIterator < E > ( node ) ; while ( iterator . hasNext ( ) ) { BinarySearchTreeNode < E > newNode = new BinarySearchTreeNode < E > ( iterator . next ( ) ) ; this . insert ( newNode ) ; } return true ; }

Inserta el subárbol dado en este árbol binario.<P> Este método copia los elementos del subárbol dado.