METHOD_0 ( ) { org . kaazing . IDENT_0 . IDENT_1 helper = org . kaazing . IDENT_0 . IDENT_1 . newInstance ( ) ; java . net . URI location = java . net . URI . create ( STRING_0 ) ; org . kaazing . IDENT_0 . ws . IDENT_2 connection = ( ( org . kaazing . IDENT_0 . ws . IDENT_2 ) ( helper . METHOD_1 ( location ) ) ) ; java . io . IDENT_3 writer = connection . METHOD_2 ( ) ; java . io . IDENT_4 reader = connection . METHOD_3 ( ) ; java . lang . String IDENT_5 = "" ; writer . write ( IDENT_5 . METHOD_4 ( ) ) ; char [ ] IDENT_6 = new char [ IDENT_5 . METHOD_4 ( ) . length ] ; int offset = 0 ; int length = IDENT_6 . length ; int IDENT_7 = 0 ; while ( ( IDENT_7 != ( - 1 ) ) && ( length > 0 ) ) { IDENT_7 = reader . read ( IDENT_6 , offset , length ) ; if ( IDENT_7 != ( - 1 ) ) { offset += IDENT_7 ; length OP_0 IDENT_7 ; } } java . lang . String IDENT_8 = java . lang . String . valueOf ( IDENT_6 ) ; IDENT_9 . METHOD_5 ( ) ; "<AssertPlaceHolder>" ; } read ( char [ ] , int , int ) { if ( ( ( offset < 0 ) || ( ( offset + length ) > ( IDENT_6 . length ) ) ) || ( length < 0 ) ) { int len = offset + length ; throw new java . lang . METHOD_6 ( java . lang . String . format ( org . kaazing . IDENT_0 . ws . internal . io . IDENT_10 . IDENT_11 , offset , len , IDENT_6 . length ) ) ; } if ( IDENT_12 . METHOD_7 ( ) ) { try { if ( ( IDENT_13 ) < ( IDENT_14 ) ) { return METHOD_8 ( IDENT_6 , offset , length ) ; } if ( ( IDENT_13 ) == ( IDENT_14 ) ) { IDENT_13 = 0 ; IDENT_14 = 0 ; } if ( ( IDENT_15 ) > ( IDENT_16 ) ) { int IDENT_17 = ( IDENT_15 ) - ( IDENT_16 ) ; java . lang . System . METHOD_9 ( IDENT_18 , IDENT_16 , IDENT_18 , 0 , IDENT_17 ) ; IDENT_16 = 0 ; IDENT_15 = IDENT_17 ; } while ( true ) { if ( ( IDENT_16 ) == ( IDENT_15 ) ) { IDENT_16 = 0 ; IDENT_15 = 0 ; int IDENT_19 = ( IDENT_18 . length ) - ( IDENT_15 ) ; int IDENT_20 = 0 ; try { IDENT_20 = in . read ( IDENT_18 , IDENT_15 , IDENT_19 ) ; if ( IDENT_20 == ( - 1 ) ) { return - 1 ; } } catch ( java . net . IDENT_21 ex ) { return - 1 ; } IDENT_16 = 0 ; IDENT_15 = IDENT_20 ; } int IDENT_22 = METHOD_10 ( ) ; if ( IDENT_22 == ( - 1 ) ) { return - 1 ; } IDENT_23 . METHOD_11 ( IDENT_24 , IDENT_16 ) ; int IDENT_25 = IDENT_23 . METHOD_12 ( ) ; if ( ( ( IDENT_23 . offset ( ) ) + METHOD_12 ) > ( IDENT_15 ) ) { if ( METHOD_12 > ( IDENT_18 . length ) ) { int IDENT_26 = connection . METHOD_13 ( ) ; throw new java . io . IOException ( java . lang . String . format ( org . kaazing . IDENT_0 . ws . internal . io . IDENT_10 . IDENT_27 , METHOD_12 , IDENT_26 ) ) ; } else { if ( ( ( IDENT_23 . offset ( ) ) + METHOD_12 ) > ( IDENT_18 . length ) ) { int len = ( IDENT_15 ) - ( IDENT_16 ) ; java . lang . System . METHOD_9 ( IDENT_18 , IDENT_16 , IDENT_18 , 0 , len ) ; IDENT_16 = 0 ; IDENT_15 = len ; } } int IDENT_28 = connection . METHOD_14 ( false , METHOD_12 ) ; int IDENT_29 = ( ( IDENT_16 ) + IDENT_28 ) - ( IDENT_15 ) ; while ( IDENT_29 > 0 ) { int IDENT_20 = in . read ( IDENT_18 , IDENT_15 , IDENT_29 ) ; if ( IDENT_20 == ( - 1 ) ) { return - 1 ; } IDENT_29 OP_0 IDENT_20 ; IDENT_15 += IDENT_20 ; } IDENT_23 . METHOD_11 ( IDENT_24 , IDENT_16 ) ; } METHOD_15 ( ) ; org . kaazing . IDENT_0 . ws . internal . IDENT_30 context = connection . METHOD_16 ( ) ; org . kaazing . IDENT_0 . ws . internal . io . IDENT_31 IDENT_32 = ( ( org . kaazing . IDENT_0 . ws . internal . io . IDENT_31 ) ( context . METHOD_17 ( ) ) ) ; IDENT_32 . METHOD_18 ( IDENT_33 , IDENT_23 . METHOD_19 ( ) ) ; connection . METHOD_20 ( IDENT_34 . METHOD_11 ( IDENT_35 , IDENT_16 ) ) ; IDENT_16 += IDENT_23 . length ( ) ; if ( ! ( METHOD_21 ( ) ) ) { break ; } } assert ( IDENT_13 ) < ( IDENT_14 ) ; return METHOD_8 ( IDENT_6 , offset , length ) ; } finally { IDENT_12 . METHOD_22 ( ) ; } } return 0 ; }
org . junit . Assert . assertEquals ( IDENT_5 , IDENT_8 )