Code example for Parcel

Methods: createStringArray, readLong, readString

0
        this.mStartTime = System.nanoTime();
        this.mStatus = Status.Queried;
    } 
 
    public Executable(Parcel parcel) {
        this.mCommandsArray = parcel.createStringArray();
        this.mStartTime = parcel.readLong();
        this.mStatus = Status.valueOf(parcel.readString());
        this.mFinishTime = parcel.readLong();
    } 
 
    public long getStartTime() { 
        return mStartTime;
    } 
 
    public String[] getCommandsArray() {
        // if the status is not finished we 
        // now consider the script Staged 
        if (getStatus() != Status.Finished) {
            setStatus(Status.Staged);
        }