public void putMap ( Map < String , String > map ) { if ( map == null ) { putNumber1 ( 0 ) ; } else { Utils . checkArgument ( map . size ( ) < 256 , "Map has to be smaller than 256 elements" ) ; putNumber1 ( map . size ( ) ) ; for ( Entry < String , String > entry : map . entrySet ( ) ) { if ( entry . getKey ( ) . contains ( "=" ) ) { throw new IllegalArgumentException ( "Keys cannot contain '=' sign. " + entry ) ; } if ( entry . getValue ( ) . contains ( "=" ) ) { throw new IllegalArgumentException ( "Values cannot contain '=' sign. " + entry ) ; } String val = entry . getKey ( ) + "=" + entry . getValue ( ) ; putString ( val ) ; } } }
Put a map of strings to the frame