Initial commit
This commit is contained in:
@@ -0,0 +1,71 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class AppGroupCreationContent implements ShareModel {
|
||||
public static final Parcelable.Creator<AppGroupCreationContent> CREATOR = new Parcelable.Creator<AppGroupCreationContent>() { // from class: com.facebook.share.model.AppGroupCreationContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public AppGroupCreationContent createFromParcel(Parcel parcel) {
|
||||
return new AppGroupCreationContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public AppGroupCreationContent[] newArray(int i) {
|
||||
return new AppGroupCreationContent[i];
|
||||
}
|
||||
};
|
||||
private final String description;
|
||||
private final String name;
|
||||
private AppGroupPrivacy privacy;
|
||||
|
||||
public enum AppGroupPrivacy {
|
||||
Open,
|
||||
Closed
|
||||
}
|
||||
|
||||
public static class Builder implements ShareModelBuilder<AppGroupCreationContent, Builder> {
|
||||
private String a;
|
||||
private String b;
|
||||
private AppGroupPrivacy c;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public AppGroupPrivacy getAppGroupPrivacy() {
|
||||
return this.privacy;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return this.description;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeString(this.name);
|
||||
parcel.writeString(this.description);
|
||||
parcel.writeSerializable(this.privacy);
|
||||
}
|
||||
|
||||
private AppGroupCreationContent(Builder builder) {
|
||||
this.name = builder.a;
|
||||
this.description = builder.b;
|
||||
this.privacy = builder.c;
|
||||
}
|
||||
|
||||
AppGroupCreationContent(Parcel parcel) {
|
||||
this.name = parcel.readString();
|
||||
this.description = parcel.readString();
|
||||
this.privacy = (AppGroupPrivacy) parcel.readSerializable();
|
||||
}
|
||||
}
|
113
sources/com/facebook/share/model/AppInviteContent.java
Normal file
113
sources/com/facebook/share/model/AppInviteContent.java
Normal file
@@ -0,0 +1,113 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class AppInviteContent implements ShareModel {
|
||||
public static final Parcelable.Creator<AppInviteContent> CREATOR = new Parcelable.Creator<AppInviteContent>() { // from class: com.facebook.share.model.AppInviteContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public AppInviteContent createFromParcel(Parcel parcel) {
|
||||
return new AppInviteContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public AppInviteContent[] newArray(int i) {
|
||||
return new AppInviteContent[i];
|
||||
}
|
||||
};
|
||||
private final String applinkUrl;
|
||||
private final Builder.Destination destination;
|
||||
private final String previewImageUrl;
|
||||
private final String promoCode;
|
||||
private final String promoText;
|
||||
|
||||
public static class Builder implements ShareModelBuilder<AppInviteContent, Builder> {
|
||||
private String a;
|
||||
private String b;
|
||||
private String c;
|
||||
private String d;
|
||||
private Destination e;
|
||||
|
||||
public enum Destination {
|
||||
FACEBOOK("facebook"),
|
||||
MESSENGER("messenger");
|
||||
|
||||
private final String name;
|
||||
|
||||
Destination(String str) {
|
||||
this.name = str;
|
||||
}
|
||||
|
||||
public boolean equalsName(String str) {
|
||||
if (str == null) {
|
||||
return false;
|
||||
}
|
||||
return this.name.equals(str);
|
||||
}
|
||||
|
||||
@Override // java.lang.Enum
|
||||
public String toString() {
|
||||
return this.name;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public String getApplinkUrl() {
|
||||
return this.applinkUrl;
|
||||
}
|
||||
|
||||
public Builder.Destination getDestination() {
|
||||
Builder.Destination destination = this.destination;
|
||||
return destination != null ? destination : Builder.Destination.FACEBOOK;
|
||||
}
|
||||
|
||||
public String getPreviewImageUrl() {
|
||||
return this.previewImageUrl;
|
||||
}
|
||||
|
||||
public String getPromotionCode() {
|
||||
return this.promoCode;
|
||||
}
|
||||
|
||||
public String getPromotionText() {
|
||||
return this.promoText;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeString(this.applinkUrl);
|
||||
parcel.writeString(this.previewImageUrl);
|
||||
parcel.writeString(this.promoText);
|
||||
parcel.writeString(this.promoCode);
|
||||
parcel.writeString(this.destination.toString());
|
||||
}
|
||||
|
||||
private AppInviteContent(Builder builder) {
|
||||
this.applinkUrl = builder.a;
|
||||
this.previewImageUrl = builder.b;
|
||||
this.promoCode = builder.c;
|
||||
this.promoText = builder.d;
|
||||
this.destination = builder.e;
|
||||
}
|
||||
|
||||
AppInviteContent(Parcel parcel) {
|
||||
this.applinkUrl = parcel.readString();
|
||||
this.previewImageUrl = parcel.readString();
|
||||
this.promoText = parcel.readString();
|
||||
this.promoCode = parcel.readString();
|
||||
String readString = parcel.readString();
|
||||
if (readString.length() > 0) {
|
||||
this.destination = Builder.Destination.valueOf(readString);
|
||||
} else {
|
||||
this.destination = Builder.Destination.FACEBOOK;
|
||||
}
|
||||
}
|
||||
}
|
132
sources/com/facebook/share/model/GameRequestContent.java
Normal file
132
sources/com/facebook/share/model/GameRequestContent.java
Normal file
@@ -0,0 +1,132 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import android.text.TextUtils;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class GameRequestContent implements ShareModel {
|
||||
public static final Parcelable.Creator<GameRequestContent> CREATOR = new Parcelable.Creator<GameRequestContent>() { // from class: com.facebook.share.model.GameRequestContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public GameRequestContent createFromParcel(Parcel parcel) {
|
||||
return new GameRequestContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public GameRequestContent[] newArray(int i) {
|
||||
return new GameRequestContent[i];
|
||||
}
|
||||
};
|
||||
private final ActionType actionType;
|
||||
private final String data;
|
||||
private final Filters filters;
|
||||
private final String message;
|
||||
private final String objectId;
|
||||
private final List<String> recipients;
|
||||
private final List<String> suggestions;
|
||||
private final String title;
|
||||
|
||||
public enum ActionType {
|
||||
SEND,
|
||||
ASKFOR,
|
||||
TURN
|
||||
}
|
||||
|
||||
public static class Builder implements ShareModelBuilder<GameRequestContent, Builder> {
|
||||
private String a;
|
||||
private List<String> b;
|
||||
private String c;
|
||||
private String d;
|
||||
private ActionType e;
|
||||
private String f;
|
||||
private Filters g;
|
||||
private List<String> h;
|
||||
}
|
||||
|
||||
public enum Filters {
|
||||
APP_USERS,
|
||||
APP_NON_USERS
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public ActionType getActionType() {
|
||||
return this.actionType;
|
||||
}
|
||||
|
||||
public String getData() {
|
||||
return this.data;
|
||||
}
|
||||
|
||||
public Filters getFilters() {
|
||||
return this.filters;
|
||||
}
|
||||
|
||||
public String getMessage() {
|
||||
return this.message;
|
||||
}
|
||||
|
||||
public String getObjectId() {
|
||||
return this.objectId;
|
||||
}
|
||||
|
||||
public List<String> getRecipients() {
|
||||
return this.recipients;
|
||||
}
|
||||
|
||||
public List<String> getSuggestions() {
|
||||
return this.suggestions;
|
||||
}
|
||||
|
||||
public String getTitle() {
|
||||
return this.title;
|
||||
}
|
||||
|
||||
public String getTo() {
|
||||
if (getRecipients() != null) {
|
||||
return TextUtils.join(",", getRecipients());
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeString(this.message);
|
||||
parcel.writeStringList(this.recipients);
|
||||
parcel.writeString(this.title);
|
||||
parcel.writeString(this.data);
|
||||
parcel.writeSerializable(this.actionType);
|
||||
parcel.writeString(this.objectId);
|
||||
parcel.writeSerializable(this.filters);
|
||||
parcel.writeStringList(this.suggestions);
|
||||
}
|
||||
|
||||
private GameRequestContent(Builder builder) {
|
||||
this.message = builder.a;
|
||||
this.recipients = builder.b;
|
||||
this.title = builder.d;
|
||||
this.data = builder.c;
|
||||
this.actionType = builder.e;
|
||||
this.objectId = builder.f;
|
||||
this.filters = builder.g;
|
||||
this.suggestions = builder.h;
|
||||
}
|
||||
|
||||
GameRequestContent(Parcel parcel) {
|
||||
this.message = parcel.readString();
|
||||
this.recipients = parcel.createStringArrayList();
|
||||
this.title = parcel.readString();
|
||||
this.data = parcel.readString();
|
||||
this.actionType = (ActionType) parcel.readSerializable();
|
||||
this.objectId = parcel.readString();
|
||||
this.filters = (Filters) parcel.readSerializable();
|
||||
this.suggestions = parcel.createStringArrayList();
|
||||
parcel.readStringList(this.suggestions);
|
||||
}
|
||||
}
|
119
sources/com/facebook/share/model/ShareContent.java
Normal file
119
sources/com/facebook/share/model/ShareContent.java
Normal file
@@ -0,0 +1,119 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.net.Uri;
|
||||
import android.os.Parcel;
|
||||
import com.facebook.share.model.ShareContent;
|
||||
import com.facebook.share.model.ShareContent.Builder;
|
||||
import com.facebook.share.model.ShareHashtag;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class ShareContent<P extends ShareContent, E extends Builder> implements ShareModel {
|
||||
private final Uri contentUrl;
|
||||
private final ShareHashtag hashtag;
|
||||
private final List<String> peopleIds;
|
||||
private final String placeId;
|
||||
private final String ref;
|
||||
|
||||
public static abstract class Builder<P extends ShareContent, E extends Builder> implements ShareModelBuilder<P, E> {
|
||||
private Uri a;
|
||||
private List<String> b;
|
||||
private String c;
|
||||
private String d;
|
||||
private ShareHashtag e;
|
||||
|
||||
public E a(Uri uri) {
|
||||
this.a = uri;
|
||||
return this;
|
||||
}
|
||||
|
||||
public E b(String str) {
|
||||
this.d = str;
|
||||
return this;
|
||||
}
|
||||
|
||||
public E a(List<String> list) {
|
||||
this.b = list == null ? null : Collections.unmodifiableList(list);
|
||||
return this;
|
||||
}
|
||||
|
||||
public E a(String str) {
|
||||
this.c = str;
|
||||
return this;
|
||||
}
|
||||
|
||||
public E a(P p) {
|
||||
if (p == null) {
|
||||
return this;
|
||||
}
|
||||
a(p.getContentUrl());
|
||||
a(p.getPeopleIds());
|
||||
a(p.getPlaceId());
|
||||
b(p.getRef());
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
protected ShareContent(Builder builder) {
|
||||
this.contentUrl = builder.a;
|
||||
this.peopleIds = builder.b;
|
||||
this.placeId = builder.c;
|
||||
this.ref = builder.d;
|
||||
this.hashtag = builder.e;
|
||||
}
|
||||
|
||||
private List<String> readUnmodifiableStringList(Parcel parcel) {
|
||||
ArrayList arrayList = new ArrayList();
|
||||
parcel.readStringList(arrayList);
|
||||
if (arrayList.size() == 0) {
|
||||
return null;
|
||||
}
|
||||
return Collections.unmodifiableList(arrayList);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public Uri getContentUrl() {
|
||||
return this.contentUrl;
|
||||
}
|
||||
|
||||
public List<String> getPeopleIds() {
|
||||
return this.peopleIds;
|
||||
}
|
||||
|
||||
public String getPlaceId() {
|
||||
return this.placeId;
|
||||
}
|
||||
|
||||
public String getRef() {
|
||||
return this.ref;
|
||||
}
|
||||
|
||||
public ShareHashtag getShareHashtag() {
|
||||
return this.hashtag;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeParcelable(this.contentUrl, 0);
|
||||
parcel.writeStringList(this.peopleIds);
|
||||
parcel.writeString(this.placeId);
|
||||
parcel.writeString(this.ref);
|
||||
parcel.writeParcelable(this.hashtag, 0);
|
||||
}
|
||||
|
||||
protected ShareContent(Parcel parcel) {
|
||||
this.contentUrl = (Uri) parcel.readParcelable(Uri.class.getClassLoader());
|
||||
this.peopleIds = readUnmodifiableStringList(parcel);
|
||||
this.placeId = parcel.readString();
|
||||
this.ref = parcel.readString();
|
||||
ShareHashtag.Builder builder = new ShareHashtag.Builder();
|
||||
builder.a(parcel);
|
||||
this.hashtag = builder.a();
|
||||
}
|
||||
}
|
70
sources/com/facebook/share/model/ShareHashtag.java
Normal file
70
sources/com/facebook/share/model/ShareHashtag.java
Normal file
@@ -0,0 +1,70 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class ShareHashtag implements ShareModel {
|
||||
public static final Parcelable.Creator<ShareHashtag> CREATOR = new Parcelable.Creator<ShareHashtag>() { // from class: com.facebook.share.model.ShareHashtag.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareHashtag createFromParcel(Parcel parcel) {
|
||||
return new ShareHashtag(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareHashtag[] newArray(int i) {
|
||||
return new ShareHashtag[i];
|
||||
}
|
||||
};
|
||||
private final String hashtag;
|
||||
|
||||
public static class Builder implements ShareModelBuilder<ShareHashtag, Builder> {
|
||||
private String a;
|
||||
|
||||
public Builder a(String str) {
|
||||
this.a = str;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder a(ShareHashtag shareHashtag) {
|
||||
if (shareHashtag == null) {
|
||||
return this;
|
||||
}
|
||||
a(shareHashtag.getHashtag());
|
||||
return this;
|
||||
}
|
||||
|
||||
Builder a(Parcel parcel) {
|
||||
a((ShareHashtag) parcel.readParcelable(ShareHashtag.class.getClassLoader()));
|
||||
return this;
|
||||
}
|
||||
|
||||
public ShareHashtag a() {
|
||||
return new ShareHashtag(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public String getHashtag() {
|
||||
return this.hashtag;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeString(this.hashtag);
|
||||
}
|
||||
|
||||
private ShareHashtag(Builder builder) {
|
||||
this.hashtag = builder.a;
|
||||
}
|
||||
|
||||
ShareHashtag(Parcel parcel) {
|
||||
this.hashtag = parcel.readString();
|
||||
}
|
||||
}
|
99
sources/com/facebook/share/model/ShareLinkContent.java
Normal file
99
sources/com/facebook/share/model/ShareLinkContent.java
Normal file
@@ -0,0 +1,99 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.net.Uri;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareContent;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareLinkContent extends ShareContent<ShareLinkContent, Builder> {
|
||||
public static final Parcelable.Creator<ShareLinkContent> CREATOR = new Parcelable.Creator<ShareLinkContent>() { // from class: com.facebook.share.model.ShareLinkContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareLinkContent createFromParcel(Parcel parcel) {
|
||||
return new ShareLinkContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareLinkContent[] newArray(int i) {
|
||||
return new ShareLinkContent[i];
|
||||
}
|
||||
};
|
||||
|
||||
@Deprecated
|
||||
private final String contentDescription;
|
||||
|
||||
@Deprecated
|
||||
private final String contentTitle;
|
||||
|
||||
@Deprecated
|
||||
private final Uri imageUrl;
|
||||
private final String quote;
|
||||
|
||||
public static final class Builder extends ShareContent.Builder<ShareLinkContent, Builder> {
|
||||
|
||||
@Deprecated
|
||||
private String f;
|
||||
|
||||
@Deprecated
|
||||
private String g;
|
||||
|
||||
@Deprecated
|
||||
private Uri h;
|
||||
private String i;
|
||||
|
||||
public ShareLinkContent a() {
|
||||
return new ShareLinkContent(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public String getContentDescription() {
|
||||
return this.contentDescription;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public String getContentTitle() {
|
||||
return this.contentTitle;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public Uri getImageUrl() {
|
||||
return this.imageUrl;
|
||||
}
|
||||
|
||||
public String getQuote() {
|
||||
return this.quote;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
parcel.writeString(this.contentDescription);
|
||||
parcel.writeString(this.contentTitle);
|
||||
parcel.writeParcelable(this.imageUrl, 0);
|
||||
parcel.writeString(this.quote);
|
||||
}
|
||||
|
||||
private ShareLinkContent(Builder builder) {
|
||||
super(builder);
|
||||
this.contentDescription = builder.f;
|
||||
this.contentTitle = builder.g;
|
||||
this.imageUrl = builder.h;
|
||||
this.quote = builder.i;
|
||||
}
|
||||
|
||||
ShareLinkContent(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.contentDescription = parcel.readString();
|
||||
this.contentTitle = parcel.readString();
|
||||
this.imageUrl = (Uri) parcel.readParcelable(Uri.class.getClassLoader());
|
||||
this.quote = parcel.readString();
|
||||
}
|
||||
}
|
69
sources/com/facebook/share/model/ShareMedia.java
Normal file
69
sources/com/facebook/share/model/ShareMedia.java
Normal file
@@ -0,0 +1,69 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class ShareMedia implements ShareModel {
|
||||
private final Bundle params;
|
||||
|
||||
public static abstract class Builder<M extends ShareMedia, B extends Builder> implements ShareModelBuilder<M, B> {
|
||||
private Bundle a = new Bundle();
|
||||
|
||||
@Deprecated
|
||||
public B a(Bundle bundle) {
|
||||
this.a.putAll(bundle);
|
||||
return this;
|
||||
}
|
||||
|
||||
public B a(M m) {
|
||||
if (m == null) {
|
||||
return this;
|
||||
}
|
||||
a(m.getParameters());
|
||||
return this;
|
||||
}
|
||||
|
||||
static List<ShareMedia> a(Parcel parcel) {
|
||||
Parcelable[] readParcelableArray = parcel.readParcelableArray(ShareMedia.class.getClassLoader());
|
||||
ArrayList arrayList = new ArrayList(readParcelableArray.length);
|
||||
for (Parcelable parcelable : readParcelableArray) {
|
||||
arrayList.add((ShareMedia) parcelable);
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
}
|
||||
|
||||
public enum Type {
|
||||
PHOTO,
|
||||
VIDEO
|
||||
}
|
||||
|
||||
protected ShareMedia(Builder builder) {
|
||||
this.params = new Bundle(builder.a);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public abstract Type getMediaType();
|
||||
|
||||
@Deprecated
|
||||
public Bundle getParameters() {
|
||||
return new Bundle(this.params);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeBundle(this.params);
|
||||
}
|
||||
|
||||
ShareMedia(Parcel parcel) {
|
||||
this.params = parcel.readBundle();
|
||||
}
|
||||
}
|
55
sources/com/facebook/share/model/ShareMediaContent.java
Normal file
55
sources/com/facebook/share/model/ShareMediaContent.java
Normal file
@@ -0,0 +1,55 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareContent;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareMediaContent extends ShareContent<ShareMediaContent, Builder> {
|
||||
public static final Parcelable.Creator<ShareMediaContent> CREATOR = new Parcelable.Creator<ShareMediaContent>() { // from class: com.facebook.share.model.ShareMediaContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareMediaContent createFromParcel(Parcel parcel) {
|
||||
return new ShareMediaContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareMediaContent[] newArray(int i) {
|
||||
return new ShareMediaContent[i];
|
||||
}
|
||||
};
|
||||
private final List<ShareMedia> media;
|
||||
|
||||
public static class Builder extends ShareContent.Builder<ShareMediaContent, Builder> {
|
||||
private final List<ShareMedia> f;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public List<ShareMedia> getMedia() {
|
||||
return this.media;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
parcel.writeParcelableArray((ShareMedia[]) this.media.toArray(), i);
|
||||
}
|
||||
|
||||
private ShareMediaContent(Builder builder) {
|
||||
super(builder);
|
||||
this.media = Collections.unmodifiableList(builder.f);
|
||||
}
|
||||
|
||||
ShareMediaContent(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.media = Arrays.asList((ShareMedia[]) parcel.readParcelableArray(ShareMedia.class.getClassLoader()));
|
||||
}
|
||||
}
|
7
sources/com/facebook/share/model/ShareModel.java
Normal file
7
sources/com/facebook/share/model/ShareModel.java
Normal file
@@ -0,0 +1,7 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface ShareModel extends Parcelable {
|
||||
}
|
9
sources/com/facebook/share/model/ShareModelBuilder.java
Normal file
9
sources/com/facebook/share/model/ShareModelBuilder.java
Normal file
@@ -0,0 +1,9 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import com.facebook.share.ShareBuilder;
|
||||
import com.facebook.share.model.ShareModel;
|
||||
import com.facebook.share.model.ShareModelBuilder;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface ShareModelBuilder<P extends ShareModel, E extends ShareModelBuilder> extends ShareBuilder<P, E> {
|
||||
}
|
59
sources/com/facebook/share/model/ShareOpenGraphAction.java
Normal file
59
sources/com/facebook/share/model/ShareOpenGraphAction.java
Normal file
@@ -0,0 +1,59 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareOpenGraphValueContainer;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareOpenGraphAction extends ShareOpenGraphValueContainer<ShareOpenGraphAction, Builder> {
|
||||
public static final Parcelable.Creator<ShareOpenGraphAction> CREATOR = new Parcelable.Creator<ShareOpenGraphAction>() { // from class: com.facebook.share.model.ShareOpenGraphAction.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareOpenGraphAction createFromParcel(Parcel parcel) {
|
||||
return new ShareOpenGraphAction(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareOpenGraphAction[] newArray(int i) {
|
||||
return new ShareOpenGraphAction[i];
|
||||
}
|
||||
};
|
||||
|
||||
public static final class Builder extends ShareOpenGraphValueContainer.Builder<ShareOpenGraphAction, Builder> {
|
||||
public Builder a(String str) {
|
||||
a("og:type", str);
|
||||
return this;
|
||||
}
|
||||
|
||||
public ShareOpenGraphAction a() {
|
||||
return new ShareOpenGraphAction(this);
|
||||
}
|
||||
|
||||
public Builder a(ShareOpenGraphAction shareOpenGraphAction) {
|
||||
if (shareOpenGraphAction == null) {
|
||||
return this;
|
||||
}
|
||||
super.a((Builder) shareOpenGraphAction);
|
||||
Builder builder = this;
|
||||
builder.a(shareOpenGraphAction.getActionType());
|
||||
return builder;
|
||||
}
|
||||
|
||||
Builder a(Parcel parcel) {
|
||||
return a((ShareOpenGraphAction) parcel.readParcelable(ShareOpenGraphAction.class.getClassLoader()));
|
||||
}
|
||||
}
|
||||
|
||||
public String getActionType() {
|
||||
return getString("og:type");
|
||||
}
|
||||
|
||||
private ShareOpenGraphAction(Builder builder) {
|
||||
super(builder);
|
||||
}
|
||||
|
||||
ShareOpenGraphAction(Parcel parcel) {
|
||||
super(parcel);
|
||||
}
|
||||
}
|
62
sources/com/facebook/share/model/ShareOpenGraphContent.java
Normal file
62
sources/com/facebook/share/model/ShareOpenGraphContent.java
Normal file
@@ -0,0 +1,62 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareContent;
|
||||
import com.facebook.share.model.ShareOpenGraphAction;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareOpenGraphContent extends ShareContent<ShareOpenGraphContent, Builder> {
|
||||
public static final Parcelable.Creator<ShareOpenGraphContent> CREATOR = new Parcelable.Creator<ShareOpenGraphContent>() { // from class: com.facebook.share.model.ShareOpenGraphContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareOpenGraphContent createFromParcel(Parcel parcel) {
|
||||
return new ShareOpenGraphContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareOpenGraphContent[] newArray(int i) {
|
||||
return new ShareOpenGraphContent[i];
|
||||
}
|
||||
};
|
||||
private final ShareOpenGraphAction action;
|
||||
private final String previewPropertyName;
|
||||
|
||||
public static final class Builder extends ShareContent.Builder<ShareOpenGraphContent, Builder> {
|
||||
private ShareOpenGraphAction f;
|
||||
private String g;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public ShareOpenGraphAction getAction() {
|
||||
return this.action;
|
||||
}
|
||||
|
||||
public String getPreviewPropertyName() {
|
||||
return this.previewPropertyName;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
parcel.writeParcelable(this.action, 0);
|
||||
parcel.writeString(this.previewPropertyName);
|
||||
}
|
||||
|
||||
private ShareOpenGraphContent(Builder builder) {
|
||||
super(builder);
|
||||
this.action = builder.f;
|
||||
this.previewPropertyName = builder.g;
|
||||
}
|
||||
|
||||
ShareOpenGraphContent(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.action = new ShareOpenGraphAction.Builder().a(parcel).a();
|
||||
this.previewPropertyName = parcel.readString();
|
||||
}
|
||||
}
|
33
sources/com/facebook/share/model/ShareOpenGraphObject.java
Normal file
33
sources/com/facebook/share/model/ShareOpenGraphObject.java
Normal file
@@ -0,0 +1,33 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareOpenGraphValueContainer;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareOpenGraphObject extends ShareOpenGraphValueContainer<ShareOpenGraphObject, Builder> {
|
||||
public static final Parcelable.Creator<ShareOpenGraphObject> CREATOR = new Parcelable.Creator<ShareOpenGraphObject>() { // from class: com.facebook.share.model.ShareOpenGraphObject.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareOpenGraphObject createFromParcel(Parcel parcel) {
|
||||
return new ShareOpenGraphObject(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareOpenGraphObject[] newArray(int i) {
|
||||
return new ShareOpenGraphObject[i];
|
||||
}
|
||||
};
|
||||
|
||||
public static final class Builder extends ShareOpenGraphValueContainer.Builder<ShareOpenGraphObject, Builder> {
|
||||
}
|
||||
|
||||
private ShareOpenGraphObject(Builder builder) {
|
||||
super(builder);
|
||||
}
|
||||
|
||||
ShareOpenGraphObject(Parcel parcel) {
|
||||
super(parcel);
|
||||
}
|
||||
}
|
@@ -0,0 +1,149 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareOpenGraphValueContainer;
|
||||
import com.facebook.share.model.ShareOpenGraphValueContainer.Builder;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Iterator;
|
||||
import java.util.Set;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class ShareOpenGraphValueContainer<P extends ShareOpenGraphValueContainer, E extends Builder> implements ShareModel {
|
||||
private final Bundle bundle;
|
||||
|
||||
public static abstract class Builder<P extends ShareOpenGraphValueContainer, E extends Builder> implements ShareModelBuilder<P, E> {
|
||||
private Bundle a = new Bundle();
|
||||
|
||||
public E a(String str, String str2) {
|
||||
this.a.putString(str, str2);
|
||||
return this;
|
||||
}
|
||||
|
||||
public E a(P p) {
|
||||
if (p != null) {
|
||||
this.a.putAll(p.getBundle());
|
||||
}
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
protected ShareOpenGraphValueContainer(Builder<P, E> builder) {
|
||||
this.bundle = (Bundle) ((Builder) builder).a.clone();
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public Object get(String str) {
|
||||
return this.bundle.get(str);
|
||||
}
|
||||
|
||||
public boolean getBoolean(String str, boolean z) {
|
||||
return this.bundle.getBoolean(str, z);
|
||||
}
|
||||
|
||||
public boolean[] getBooleanArray(String str) {
|
||||
return this.bundle.getBooleanArray(str);
|
||||
}
|
||||
|
||||
public Bundle getBundle() {
|
||||
return (Bundle) this.bundle.clone();
|
||||
}
|
||||
|
||||
public double getDouble(String str, double d) {
|
||||
return this.bundle.getDouble(str, d);
|
||||
}
|
||||
|
||||
public double[] getDoubleArray(String str) {
|
||||
return this.bundle.getDoubleArray(str);
|
||||
}
|
||||
|
||||
public int getInt(String str, int i) {
|
||||
return this.bundle.getInt(str, i);
|
||||
}
|
||||
|
||||
public int[] getIntArray(String str) {
|
||||
return this.bundle.getIntArray(str);
|
||||
}
|
||||
|
||||
public long getLong(String str, long j) {
|
||||
return this.bundle.getLong(str, j);
|
||||
}
|
||||
|
||||
public long[] getLongArray(String str) {
|
||||
return this.bundle.getLongArray(str);
|
||||
}
|
||||
|
||||
public ShareOpenGraphObject getObject(String str) {
|
||||
Object obj = this.bundle.get(str);
|
||||
if (obj instanceof ShareOpenGraphObject) {
|
||||
return (ShareOpenGraphObject) obj;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public ArrayList<ShareOpenGraphObject> getObjectArrayList(String str) {
|
||||
ArrayList parcelableArrayList = this.bundle.getParcelableArrayList(str);
|
||||
if (parcelableArrayList == null) {
|
||||
return null;
|
||||
}
|
||||
ArrayList<ShareOpenGraphObject> arrayList = new ArrayList<>();
|
||||
Iterator it = parcelableArrayList.iterator();
|
||||
while (it.hasNext()) {
|
||||
Parcelable parcelable = (Parcelable) it.next();
|
||||
if (parcelable instanceof ShareOpenGraphObject) {
|
||||
arrayList.add((ShareOpenGraphObject) parcelable);
|
||||
}
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
|
||||
public SharePhoto getPhoto(String str) {
|
||||
Parcelable parcelable = this.bundle.getParcelable(str);
|
||||
if (parcelable instanceof SharePhoto) {
|
||||
return (SharePhoto) parcelable;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public ArrayList<SharePhoto> getPhotoArrayList(String str) {
|
||||
ArrayList parcelableArrayList = this.bundle.getParcelableArrayList(str);
|
||||
if (parcelableArrayList == null) {
|
||||
return null;
|
||||
}
|
||||
ArrayList<SharePhoto> arrayList = new ArrayList<>();
|
||||
Iterator it = parcelableArrayList.iterator();
|
||||
while (it.hasNext()) {
|
||||
Parcelable parcelable = (Parcelable) it.next();
|
||||
if (parcelable instanceof SharePhoto) {
|
||||
arrayList.add((SharePhoto) parcelable);
|
||||
}
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
|
||||
public String getString(String str) {
|
||||
return this.bundle.getString(str);
|
||||
}
|
||||
|
||||
public ArrayList<String> getStringArrayList(String str) {
|
||||
return this.bundle.getStringArrayList(str);
|
||||
}
|
||||
|
||||
public Set<String> keySet() {
|
||||
return this.bundle.keySet();
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeBundle(this.bundle);
|
||||
}
|
||||
|
||||
ShareOpenGraphValueContainer(Parcel parcel) {
|
||||
this.bundle = parcel.readBundle(Builder.class.getClassLoader());
|
||||
}
|
||||
}
|
156
sources/com/facebook/share/model/SharePhoto.java
Normal file
156
sources/com/facebook/share/model/SharePhoto.java
Normal file
@@ -0,0 +1,156 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.graphics.Bitmap;
|
||||
import android.net.Uri;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareMedia;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class SharePhoto extends ShareMedia {
|
||||
public static final Parcelable.Creator<SharePhoto> CREATOR = new Parcelable.Creator<SharePhoto>() { // from class: com.facebook.share.model.SharePhoto.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public SharePhoto createFromParcel(Parcel parcel) {
|
||||
return new SharePhoto(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public SharePhoto[] newArray(int i) {
|
||||
return new SharePhoto[i];
|
||||
}
|
||||
};
|
||||
private final Bitmap bitmap;
|
||||
private final String caption;
|
||||
private final Uri imageUrl;
|
||||
private final boolean userGenerated;
|
||||
|
||||
public static final class Builder extends ShareMedia.Builder<SharePhoto, Builder> {
|
||||
private Bitmap b;
|
||||
private Uri c;
|
||||
private boolean d;
|
||||
private String e;
|
||||
|
||||
public Builder a(Bitmap bitmap) {
|
||||
this.b = bitmap;
|
||||
return this;
|
||||
}
|
||||
|
||||
Bitmap b() {
|
||||
return this.b;
|
||||
}
|
||||
|
||||
Uri c() {
|
||||
return this.c;
|
||||
}
|
||||
|
||||
static List<SharePhoto> c(Parcel parcel) {
|
||||
List<ShareMedia> a = ShareMedia.Builder.a(parcel);
|
||||
ArrayList arrayList = new ArrayList();
|
||||
for (ShareMedia shareMedia : a) {
|
||||
if (shareMedia instanceof SharePhoto) {
|
||||
arrayList.add((SharePhoto) shareMedia);
|
||||
}
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
|
||||
public Builder a(Uri uri) {
|
||||
this.c = uri;
|
||||
return this;
|
||||
}
|
||||
|
||||
Builder b(Parcel parcel) {
|
||||
return a((SharePhoto) parcel.readParcelable(SharePhoto.class.getClassLoader()));
|
||||
}
|
||||
|
||||
public Builder a(boolean z) {
|
||||
this.d = z;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder a(String str) {
|
||||
this.e = str;
|
||||
return this;
|
||||
}
|
||||
|
||||
public SharePhoto a() {
|
||||
return new SharePhoto(this);
|
||||
}
|
||||
|
||||
public Builder a(SharePhoto sharePhoto) {
|
||||
if (sharePhoto == null) {
|
||||
return this;
|
||||
}
|
||||
super.a((Builder) sharePhoto);
|
||||
Builder builder = this;
|
||||
builder.a(sharePhoto.getBitmap());
|
||||
builder.a(sharePhoto.getImageUrl());
|
||||
builder.a(sharePhoto.getUserGenerated());
|
||||
builder.a(sharePhoto.getCaption());
|
||||
return builder;
|
||||
}
|
||||
|
||||
static void a(Parcel parcel, int i, List<SharePhoto> list) {
|
||||
ShareMedia[] shareMediaArr = new ShareMedia[list.size()];
|
||||
for (int i2 = 0; i2 < list.size(); i2++) {
|
||||
shareMediaArr[i2] = list.get(i2);
|
||||
}
|
||||
parcel.writeParcelableArray(shareMediaArr, i);
|
||||
}
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareMedia, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public Bitmap getBitmap() {
|
||||
return this.bitmap;
|
||||
}
|
||||
|
||||
public String getCaption() {
|
||||
return this.caption;
|
||||
}
|
||||
|
||||
public Uri getImageUrl() {
|
||||
return this.imageUrl;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareMedia
|
||||
public ShareMedia.Type getMediaType() {
|
||||
return ShareMedia.Type.PHOTO;
|
||||
}
|
||||
|
||||
public boolean getUserGenerated() {
|
||||
return this.userGenerated;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareMedia, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
parcel.writeParcelable(this.bitmap, 0);
|
||||
parcel.writeParcelable(this.imageUrl, 0);
|
||||
parcel.writeByte(this.userGenerated ? (byte) 1 : (byte) 0);
|
||||
parcel.writeString(this.caption);
|
||||
}
|
||||
|
||||
private SharePhoto(Builder builder) {
|
||||
super(builder);
|
||||
this.bitmap = builder.b;
|
||||
this.imageUrl = builder.c;
|
||||
this.userGenerated = builder.d;
|
||||
this.caption = builder.e;
|
||||
}
|
||||
|
||||
SharePhoto(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.bitmap = (Bitmap) parcel.readParcelable(Bitmap.class.getClassLoader());
|
||||
this.imageUrl = (Uri) parcel.readParcelable(Uri.class.getClassLoader());
|
||||
this.userGenerated = parcel.readByte() != 0;
|
||||
this.caption = parcel.readString();
|
||||
}
|
||||
}
|
94
sources/com/facebook/share/model/SharePhotoContent.java
Normal file
94
sources/com/facebook/share/model/SharePhotoContent.java
Normal file
@@ -0,0 +1,94 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareContent;
|
||||
import com.facebook.share.model.SharePhoto;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class SharePhotoContent extends ShareContent<SharePhotoContent, Builder> {
|
||||
public static final Parcelable.Creator<SharePhotoContent> CREATOR = new Parcelable.Creator<SharePhotoContent>() { // from class: com.facebook.share.model.SharePhotoContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public SharePhotoContent createFromParcel(Parcel parcel) {
|
||||
return new SharePhotoContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public SharePhotoContent[] newArray(int i) {
|
||||
return new SharePhotoContent[i];
|
||||
}
|
||||
};
|
||||
private final List<SharePhoto> photos;
|
||||
|
||||
public static class Builder extends ShareContent.Builder<SharePhotoContent, Builder> {
|
||||
private final List<SharePhoto> f = new ArrayList();
|
||||
|
||||
public Builder b(List<SharePhoto> list) {
|
||||
if (list != null) {
|
||||
Iterator<SharePhoto> it = list.iterator();
|
||||
while (it.hasNext()) {
|
||||
a(it.next());
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder c(List<SharePhoto> list) {
|
||||
this.f.clear();
|
||||
b(list);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder a(SharePhoto sharePhoto) {
|
||||
if (sharePhoto != null) {
|
||||
this.f.add(new SharePhoto.Builder().a(sharePhoto).a());
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public SharePhotoContent a() {
|
||||
return new SharePhotoContent(this);
|
||||
}
|
||||
|
||||
public Builder a(SharePhotoContent sharePhotoContent) {
|
||||
if (sharePhotoContent == null) {
|
||||
return this;
|
||||
}
|
||||
super.a((Builder) sharePhotoContent);
|
||||
Builder builder = this;
|
||||
builder.b(sharePhotoContent.getPhotos());
|
||||
return builder;
|
||||
}
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public List<SharePhoto> getPhotos() {
|
||||
return this.photos;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
SharePhoto.Builder.a(parcel, i, this.photos);
|
||||
}
|
||||
|
||||
private SharePhotoContent(Builder builder) {
|
||||
super(builder);
|
||||
this.photos = Collections.unmodifiableList(builder.f);
|
||||
}
|
||||
|
||||
SharePhotoContent(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.photos = Collections.unmodifiableList(SharePhoto.Builder.c(parcel));
|
||||
}
|
||||
}
|
81
sources/com/facebook/share/model/ShareVideo.java
Normal file
81
sources/com/facebook/share/model/ShareVideo.java
Normal file
@@ -0,0 +1,81 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.net.Uri;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareMedia;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareVideo extends ShareMedia {
|
||||
public static final Parcelable.Creator<ShareVideo> CREATOR = new Parcelable.Creator<ShareVideo>() { // from class: com.facebook.share.model.ShareVideo.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareVideo createFromParcel(Parcel parcel) {
|
||||
return new ShareVideo(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareVideo[] newArray(int i) {
|
||||
return new ShareVideo[i];
|
||||
}
|
||||
};
|
||||
private final Uri localUrl;
|
||||
|
||||
public static final class Builder extends ShareMedia.Builder<ShareVideo, Builder> {
|
||||
private Uri b;
|
||||
|
||||
Builder b(Parcel parcel) {
|
||||
return a((ShareVideo) parcel.readParcelable(ShareVideo.class.getClassLoader()));
|
||||
}
|
||||
|
||||
public Builder a(Uri uri) {
|
||||
this.b = uri;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ShareVideo a() {
|
||||
return new ShareVideo(this);
|
||||
}
|
||||
|
||||
public Builder a(ShareVideo shareVideo) {
|
||||
if (shareVideo == null) {
|
||||
return this;
|
||||
}
|
||||
super.a((Builder) shareVideo);
|
||||
Builder builder = this;
|
||||
builder.a(shareVideo.getLocalUrl());
|
||||
return builder;
|
||||
}
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareMedia, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public Uri getLocalUrl() {
|
||||
return this.localUrl;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareMedia
|
||||
public ShareMedia.Type getMediaType() {
|
||||
return ShareMedia.Type.VIDEO;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareMedia, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
parcel.writeParcelable(this.localUrl, 0);
|
||||
}
|
||||
|
||||
private ShareVideo(Builder builder) {
|
||||
super(builder);
|
||||
this.localUrl = builder.b;
|
||||
}
|
||||
|
||||
ShareVideo(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.localUrl = (Uri) parcel.readParcelable(Uri.class.getClassLoader());
|
||||
}
|
||||
}
|
86
sources/com/facebook/share/model/ShareVideoContent.java
Normal file
86
sources/com/facebook/share/model/ShareVideoContent.java
Normal file
@@ -0,0 +1,86 @@
|
||||
package com.facebook.share.model;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.facebook.share.model.ShareContent;
|
||||
import com.facebook.share.model.SharePhoto;
|
||||
import com.facebook.share.model.ShareVideo;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ShareVideoContent extends ShareContent<ShareVideoContent, Builder> implements ShareModel {
|
||||
public static final Parcelable.Creator<ShareVideoContent> CREATOR = new Parcelable.Creator<ShareVideoContent>() { // from class: com.facebook.share.model.ShareVideoContent.1
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareVideoContent createFromParcel(Parcel parcel) {
|
||||
return new ShareVideoContent(parcel);
|
||||
}
|
||||
|
||||
/* JADX WARN: Can't rename method to resolve collision */
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public ShareVideoContent[] newArray(int i) {
|
||||
return new ShareVideoContent[i];
|
||||
}
|
||||
};
|
||||
private final String contentDescription;
|
||||
private final String contentTitle;
|
||||
private final SharePhoto previewPhoto;
|
||||
private final ShareVideo video;
|
||||
|
||||
public static final class Builder extends ShareContent.Builder<ShareVideoContent, Builder> {
|
||||
private String f;
|
||||
private String g;
|
||||
private SharePhoto h;
|
||||
private ShareVideo i;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public String getContentDescription() {
|
||||
return this.contentDescription;
|
||||
}
|
||||
|
||||
public String getContentTitle() {
|
||||
return this.contentTitle;
|
||||
}
|
||||
|
||||
public SharePhoto getPreviewPhoto() {
|
||||
return this.previewPhoto;
|
||||
}
|
||||
|
||||
public ShareVideo getVideo() {
|
||||
return this.video;
|
||||
}
|
||||
|
||||
@Override // com.facebook.share.model.ShareContent, android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
super.writeToParcel(parcel, i);
|
||||
parcel.writeString(this.contentDescription);
|
||||
parcel.writeString(this.contentTitle);
|
||||
parcel.writeParcelable(this.previewPhoto, 0);
|
||||
parcel.writeParcelable(this.video, 0);
|
||||
}
|
||||
|
||||
private ShareVideoContent(Builder builder) {
|
||||
super(builder);
|
||||
this.contentDescription = builder.f;
|
||||
this.contentTitle = builder.g;
|
||||
this.previewPhoto = builder.h;
|
||||
this.video = builder.i;
|
||||
}
|
||||
|
||||
ShareVideoContent(Parcel parcel) {
|
||||
super(parcel);
|
||||
this.contentDescription = parcel.readString();
|
||||
this.contentTitle = parcel.readString();
|
||||
SharePhoto.Builder b = new SharePhoto.Builder().b(parcel);
|
||||
if (b.c() == null && b.b() == null) {
|
||||
this.previewPhoto = null;
|
||||
} else {
|
||||
this.previewPhoto = b.a();
|
||||
}
|
||||
this.video = new ShareVideo.Builder().b(parcel).a();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user