Java源码示例:org.parceler.ParcelConstructor
示例1
@ParcelConstructor
TuneResult(boolean lf, boolean hf, float[] lfVoltages, Float v125, Float v134, Float peakF,
Float peakV, Float hfVoltage) {
this.lf = lf;
this.hf = hf;
this.lfVoltages = lfVoltages;
this.v125 = v125;
this.v134 = v134;
this.peakF = peakF;
this.peakV = peakV;
this.hfVoltage = hfVoltage;
}
示例2
@ParcelConstructor
AnchorParams(@IdRes final int anchorId,
final int anchorGravity,
final int leftMargin,
final int topMargin,
final int rightMargin,
final int bottomMargin) {
this.anchorId = anchorId;
this.anchorGravity = anchorGravity;
this.leftMargin = leftMargin;
this.topMargin = topMargin;
this.rightMargin = rightMargin;
this.bottomMargin = bottomMargin;
}
示例3
@ParcelConstructor
public ParcelerResponse(
List<User> users,
String status,
boolean isRealJson) {
this.users = users;
this.status = status;
this.isRealJson = isRealJson;
}
示例4
@ParcelConstructor
public Friend(
int id,
String name) {
this.id = id;
this.name = name;
}
示例5
@ParcelConstructor
public Image(
String id,
String format,
String url,
String description) {
this.id = id;
this.format = format;
this.url = url;
this.description = description;
}
示例6
@ParcelConstructor
public Name(
String first,
String last) {
this.first = first;
this.last = last;
}
示例7
@ParcelConstructor
public DeniedPermission(String permission, boolean shouldShowRationale) {
this.permission = permission;
this.shouldShowRationale = shouldShowRationale;
}
示例8
@Inject
@ParcelConstructor
HomeViewModel(@NonNull final NavigationViewModel navigationModel) {
this.navigationModel = navigationModel;
}
示例9
@ParcelConstructor
public HomeStackable(String name) {
this.name = name;
}
示例10
@ParcelConstructor
public User(
String id,
int index,
String guid,
boolean isActive,
String balance,
String pictureUrl,
int age,
Name name,
String company,
String email,
String address,
String about,
String registered,
double latitude,
double longitude,
List<String> tags,
List<Integer> range,
List<Friend> friends,
List<Image> images,
String greeting,
String favoriteFruit,
String eyeColor,
String phone) {
this.id = id;
this.index = index;
this.guid = guid;
this.isActive = isActive;
this.balance = balance;
this.pictureUrl = pictureUrl;
this.age = age;
this.name = name;
this.company = company;
this.email = email;
this.address = address;
this.about = about;
this.registered = registered;
this.latitude = latitude;
this.longitude = longitude;
this.tags = tags;
this.range = range;
this.friends = friends;
this.images = images;
this.greeting = greeting;
this.favoriteFruit = favoriteFruit;
this.eyeColor = eyeColor;
this.phone = phone;
}
示例11
@ParcelConstructor
public StringParcel(String name) {
this.name = name;
}
示例12
@ParcelConstructor
public ParcelerTestModel(Date firstDate, Date secondDate, String someString) {
this.firstDate = firstDate;
this.secondDate = secondDate;
this.someString = someString;
}
示例13
@ParcelConstructor Shot() {}
示例14
@ParcelConstructor Comment() {}