blob: 9830d402204520ca10fb54837f52fd7a39057d82 [file] [log] [blame]
<?xml version="1.0" encoding="utf-8"?>
<!--
This descriptor will generate the Parcelable class com.example.GeneratedStudent,
but its static CREATOR will produce a com.example.Student. The expectation is that
a user of this descriptor will want to subclass GeneratedStudent with their own
Student class that includes additional instance methods, so it is important that a
Parcel be able to be un-parceled as a Student rather than a GeneratedStudent.
-->
<class name="com.example.GeneratedStudent"
creatorClass="com.example.Student"
extends="Person"
superParams="boolean isMale, int age">
<imports>
import com.example.Person;
import com.example.Principal;
import com.example.Teacher;
import com.google.common.collect.ImmutableList;
</imports>
<!--
Note how curly braces can be used instead of angle brackets in the type attribute
below to identify generics, as less-than signs have to be escaped, making them hard
to read in XML files.
-->
<fields defaultVisibility="protected">
<field type="int" name="id" jsonProperty="" />
<field type="String" name="name" jsonProperty="" />
<field type="float" name="gpa" jsonProperty="" />
<field type="byte" name="daysOfSchoolLeft" jsonProperty="days_of_school_left" />
<field type="Principal" name="principal" jsonProperty="" />
<field type="boolean" name="isGraduated" jsonProperty="is_graduated" />
<field type="List{String}" name="grades" jsonProperty="" />
<field type="String[]" name="schedule" jsonProperty="" />
<field type="List{Teacher}" name="teachers" jsonProperty="" defaultValue="ImmutableList.of()" />
<field type="List" name="metadata" visibility="private" mutable="true" />
</fields>
</class>