notes注释

ZhengLiJie_branch
zlj 3 months ago
parent bf28390b3d
commit 9228ce6fe0

@ -18,10 +18,29 @@ package net.micode.notes.data;
import android.net.Uri;
public class Notes {
/**
* Authority ContentProvider
*/
public static final String AUTHORITY = "micode_notes";
/**
* TAG
*/
public static final String TAG = "Notes";
/**
*
*/
public static final int TYPE_NOTE = 0;
/**
*
*/
public static final int TYPE_FOLDER = 1;
/**
*
*/
public static final int TYPE_SYSTEM = 2;
/**
@ -30,41 +49,104 @@ public class Notes {
* {@link Notes#ID_TEMPARAY_FOLDER } is for notes belonging no folder
* {@link Notes#ID_CALL_RECORD_FOLDER} is to store call records
*/
/**
* ID
*/
public static final int ID_ROOT_FOLDER = 0;
/**
* ID
*/
public static final int ID_TEMPARAY_FOLDER = -1;
/**
* ID
*/
public static final int ID_CALL_RECORD_FOLDER = -2;
/**
* ID
*/
public static final int ID_TRASH_FOLER = -3;
/**
* Intent Extra
*/
public static final String INTENT_EXTRA_ALERT_DATE = "net.micode.notes.alert_date";
/**
* Intent Extra ID
*/
public static final String INTENT_EXTRA_BACKGROUND_ID = "net.micode.notes.background_color_id";
/**
* Intent Extra ID
*/
public static final String INTENT_EXTRA_WIDGET_ID = "net.micode.notes.widget_id";
/**
* Intent Extra
*/
public static final String INTENT_EXTRA_WIDGET_TYPE = "net.micode.notes.widget_type";
/**
* Intent Extra ID
*/
public static final String INTENT_EXTRA_FOLDER_ID = "net.micode.notes.folder_id";
/**
* Intent Extra
*/
public static final String INTENT_EXTRA_CALL_DATE = "net.micode.notes.call_date";
/**
*
*/
public static final int TYPE_WIDGET_INVALIDE = -1;
/**
* 2x
*/
public static final int TYPE_WIDGET_2X = 0;
/**
* 4x
*/
public static final int TYPE_WIDGET_4X = 1;
/**
* MIME
*/
public static class DataConstants {
/**
* MIME
*/
public static final String NOTE = TextNote.CONTENT_ITEM_TYPE;
/**
* MIME
*/
public static final String CALL_NOTE = CallNote.CONTENT_ITEM_TYPE;
}
/**
* Uri to query all notes and folders
* Uri
*/
public static final Uri CONTENT_NOTE_URI = Uri.parse("content://" + AUTHORITY + "/note");
/**
* Uri to query data
* Uri
*/
public static final Uri CONTENT_DATA_URI = Uri.parse("content://" + AUTHORITY + "/data");
public interface NoteColumns {
/**
* The unique ID for a row
* <P> Type: INTEGER (long) </P>
* ID
* <P>: INTEGER (long)</P>
*/
public static final String ID = "_id";
@ -169,8 +251,8 @@ public class Notes {
public interface DataColumns {
/**
* The unique ID for a row
* <P> Type: INTEGER (long) </P>
* ID
* <P>: INTEGER (long)</P>
*/
public static final String ID = "_id";
@ -240,40 +322,68 @@ public class Notes {
*/
public static final String DATA5 = "data5";
}
/**
*
* DataColumns
*/
public static final class TextNote implements DataColumns {
/**
* Mode to indicate the text in check list mode or not
* <P> Type: Integer 1:check list mode 0: normal mode </P>
*
* <P>: Integer 1: 0:</P>
*/
public static final String MODE = DATA1;
/**
*
*/
public static final int MODE_CHECK_LIST = 1;
/**
* MIME
*/
public static final String CONTENT_TYPE = "vnd.android.cursor.dir/text_note";
/**
* MIME
*/
public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/text_note";
/**
* Uri
*/
public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/text_note");
}
/**
*
* DataColumns
*/
public static final class CallNote implements DataColumns {
/**
* Call date for this record
* <P> Type: INTEGER (long) </P>
*
* <P>: INTEGER (long)</P>
*/
public static final String CALL_DATE = DATA1;
/**
* Phone number for this record
* <P> Type: TEXT </P>
*
* <P>: TEXT</P>
*/
public static final String PHONE_NUMBER = DATA3;
/**
* MIME
*/
public static final String CONTENT_TYPE = "vnd.android.cursor.dir/call_note";
/**
* MIME
*/
public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/call_note";
/**
* Uri
*/
public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/call_note");
}
}

Loading…
Cancel
Save