Android Open Source - JayJayLab-Android-Demo Path






From Project

Back to project page JayJayLab-Android-Demo.

License

The source code is released under:

Apache License

If you think the Android project JayJayLab-Android-Demo listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.jayjaylab.androiddemo.app.greyhound.model;
//from   w w  w  .  jav a2s.com
import android.os.Parcel;
import android.os.Parcelable;

/**
 * This class contains an instance of database Path entity produced by GreenDao Framework.<br>
 * The purpose of this class is to provide a parcelable class of the database entity created by
 * GreenDao framework.
 *
 * Created by jongjoo on 12/7/14.
 */
public class Path implements Parcelable {
    com.jayjaylab.androiddemo.Path pathEntity;

    public Path() {
        if(pathEntity == null) {
            pathEntity = new com.jayjaylab.androiddemo.Path();
        }
    }

    public Path(Parcel in) {
        if(pathEntity == null) {
            pathEntity = new com.jayjaylab.androiddemo.Path();
        }

        readFromParcel(in);
    }

    public String toString() {
        StringBuilder builder = new StringBuilder();
        builder.append("id : " + pathEntity.getId());
        builder.append(", startTime : " + pathEntity.getStartTime());
        builder.append(", endTime : " + pathEntity.getEndTime());
        builder.append(", gpxPath : " + pathEntity.getGpxPath());

        return builder.toString();
    }

    public com.jayjaylab.androiddemo.Path getPathEntity() {
        return pathEntity;
    }

    protected void readFromParcel(Parcel in) {
        final Long id = in.readLong();
        pathEntity.setId(id == -1L ? null : id);
        pathEntity.setStartTime(in.readString());
        pathEntity.setEndTime(in.readString());
        pathEntity.setGpxPath(in.readString());
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeLong(pathEntity.getId() == null ? -1L : pathEntity.getId());
        dest.writeString(pathEntity.getStartTime());
        dest.writeString(pathEntity.getEndTime());
        dest.writeString(pathEntity.getGpxPath());
    }

    public static final Parcelable.Creator<Path> CREATOR =
            new Parcelable.Creator<Path>() {
                @Override
                public Path createFromParcel(Parcel source) {
                    return new Path(source);
                }

                @Override
                public Path[] newArray(int size) {
                    return new Path[size];
                }
            };
}




Java Source Code List

com.jayjaylab.androiddemo.ActivityIntroTest.java
com.jayjaylab.androiddemo.Application.java
com.jayjaylab.androiddemo.DaoMaster.java
com.jayjaylab.androiddemo.DaoSession.java
com.jayjaylab.androiddemo.PathDao.java
com.jayjaylab.androiddemo.Path.java
com.jayjaylab.androiddemo.app.greyhound.activity.ActivityMain.java
com.jayjaylab.androiddemo.app.greyhound.activity.ActivityMap.java
com.jayjaylab.androiddemo.app.greyhound.adapter.AdapterPathHistory.java
com.jayjaylab.androiddemo.app.greyhound.event.OnGPXParsingCompleteEvent.java
com.jayjaylab.androiddemo.app.greyhound.event.OnReceiveResultEvent.java
com.jayjaylab.androiddemo.app.greyhound.fragment.FragmentPathHistory.java
com.jayjaylab.androiddemo.app.greyhound.model.Path.java
com.jayjaylab.androiddemo.app.greyhound.service.ServiceRecordingPath.java
com.jayjaylab.androiddemo.app.greyhound.util.Constants.java
com.jayjaylab.androiddemo.app.greyhound.util.GPXParser.java
com.jayjaylab.androiddemo.app.greyhound.util.GPXWriter.java
com.jayjaylab.androiddemo.app.greyhound.util.MyResultReceiver.java
com.jayjaylab.androiddemo.app.greyhound.util.PreferenceHelper.java
com.jayjaylab.androiddemo.dialog.ProgressDialog.java
com.jayjaylab.androiddemo.event.OnClickEvent.java
com.jayjaylab.androiddemo.event.OnLongClickEvent.java
com.jayjaylab.androiddemo.event.ProgressBarEvent.java
com.jayjaylab.androiddemo.main.activity.ActivityBase.java
com.jayjaylab.androiddemo.main.activity.ActivityIntro.java
com.jayjaylab.androiddemo.main.activity.ActivityMain.java
com.jayjaylab.androiddemo.main.adapter.AdapterMain.java
com.jayjaylab.androiddemo.main.model.App.java
com.jayjaylab.androiddemo.util.AndroidHelper.java
com.jayjaylab.androiddemo.util.NIOHelper.java
com.jayjaylab.androiddemo.view.BubbleViewMaker.java
com.jayjaylab.androiddemo.view.CardView.java
com.jayjaylab.androiddemo.view.ImageViewThreadPool.java
com.jayjaylab.androiddemo.view.ViewThreadPool.java
de.greenrobot.daogenerator.gentest.ExampleDaoGenerator.java