コード例 #1
0
 public MediaWrapper(Parcel in) {
   mUri = in.readParcelable(Uri.class.getClassLoader());
   init(
       in.readLong(),
       in.readLong(),
       in.readInt(),
       (Bitmap) in.readParcelable(Bitmap.class.getClassLoader()),
       in.readString(),
       in.readString(),
       in.readString(),
       in.readString(),
       in.readString(),
       in.readInt(),
       in.readInt(),
       in.readString(),
       in.readInt(),
       in.readInt(),
       in.readInt(),
       in.readInt(),
       in.readLong());
 }
コード例 #2
0
 public MediaWrapper(
     Uri uri,
     long time,
     long length,
     int type,
     Bitmap picture,
     String title,
     String artist,
     String genre,
     String album,
     String albumArtist,
     int width,
     int height,
     String artworkURL,
     int audio,
     int spu,
     int trackNumber,
     int discNumber,
     long lastModified) {
   mUri = uri;
   init(
       time,
       length,
       type,
       picture,
       title,
       artist,
       genre,
       album,
       albumArtist,
       width,
       height,
       artworkURL,
       audio,
       spu,
       trackNumber,
       discNumber,
       lastModified);
 }
コード例 #3
0
  /**
   * Create a new MediaWrapper
   *
   * @param uri Should not be null.
   */
  public MediaWrapper(Uri uri) {
    if (uri == null) throw new NullPointerException("uri was null");

    mUri = uri;
    init(null);
  }
コード例 #4
0
  /**
   * Create a new MediaWrapper
   *
   * @param media should be parsed and not NULL
   */
  public MediaWrapper(Media media) {
    if (media == null) throw new NullPointerException("media was null");

    mUri = media.getUri();
    init(media);
  }