public static EncodedImage create(byte[] data){
  if (data == null) {
    throw new NullPointerException();
  }
  return new EncodedImage(new byte[][]{data});
}

public static EncodedImage create ( byte [ ] data ) { if ( data == null ) { throw new NullPointerException ( ) ; } return new EncodedImage ( new byte [ ] [ ] { data } ) ; }
creates an image from the given byte array
