Home | History | Annotate | Download | only in notepad

Lines Matching refs:Notes

51  * Provides access to a database of notes. Each note has a title, the note
82 NotePad.Notes._ID, // Projection position 0, the note's id
83 NotePad.Notes.COLUMN_NAME_NOTE, // Projection position 1, the note's content
84 NotePad.Notes.COLUMN_NAME_TITLE, // Projection position 2, the note's title
93 // The incoming URI matches the Notes URI pattern
94 private static final int NOTES = 1;
122 // Add a pattern that routes URIs terminated with "notes" to a NOTES operation
123 sUriMatcher.addURI(NotePad.AUTHORITY, "notes", NOTES);
125 // Add a pattern that routes URIs terminated with "notes" plus an integer
127 sUriMatcher.addURI(NotePad.AUTHORITY, "notes/#", NOTE_ID);
129 // Add a pattern that routes URIs terminated with live_folders/notes to a
131 sUriMatcher.addURI(NotePad.AUTHORITY, "live_folders/notes", LIVE_FOLDER_NOTES);
142 sNotesProjectionMap.put(NotePad.Notes._ID, NotePad.Notes._ID);
145 sNotesProjectionMap.put(NotePad.Notes.COLUMN_NAME_TITLE, NotePad.Notes.COLUMN_NAME_TITLE);
148 sNotesProjectionMap.put(NotePad.Notes.COLUMN_NAME_NOTE, NotePad.Notes.COLUMN_NAME_NOTE);
151 sNotesProjectionMap.put(NotePad.Notes.COLUMN_NAME_CREATE_DATE,
152 NotePad.Notes.COLUMN_NAME_CREATE_DATE);
156 NotePad.Notes.COLUMN_NAME_MODIFICATION_DATE,
157 NotePad.Notes.COLUMN_NAME_MODIFICATION_DATE);
167 sLiveFolderProjectionMap.put(LiveFolders._ID, NotePad.Notes._ID + " AS " + LiveFolders._ID);
170 sLiveFolderProjectionMap.put(LiveFolders.NAME, NotePad.Notes.COLUMN_NAME_TITLE + " AS " +
194 db.execSQL("CREATE TABLE " + NotePad.Notes.TABLE_NAME + " ("
195 + NotePad.Notes._ID + " INTEGER PRIMARY KEY,"
196 + NotePad.Notes.COLUMN_NAME_TITLE + " TEXT,"
197 + NotePad.Notes.COLUMN_NAME_NOTE + " TEXT,"
198 + NotePad.Notes.COLUMN_NAME_CREATE_DATE + " INTEGER,"
199 + NotePad.Notes.COLUMN_NAME_MODIFICATION_DATE + " INTEGER"
218 db.execSQL("DROP TABLE IF EXISTS notes");
257 qb.setTables(NotePad.Notes.TABLE_NAME);
263 // If the incoming URI is for notes, chooses the Notes projection
264 case NOTES:
275 NotePad.Notes._ID + // the name of the ID column
278 uri.getPathSegments().get(NotePad.Notes.NOTE_ID_PATH_POSITION));
295 orderBy = NotePad.Notes.DEFAULT_SORT_ORDER;
340 // If the pattern is for notes or live folders, returns the general content type.
341 case NOTES:
343 return NotePad.Notes.CONTENT_TYPE;
347 return NotePad.Notes.CONTENT_ITEM_TYPE;
364 * Returns the types of available data streams. URIs to specific notes are supported.
380 // If the pattern is for notes or live folders, return null. Data streams are not
382 case NOTES:
502 if (sUriMatcher.match(uri) != NOTES) {
522 if (values.containsKey(NotePad.Notes.COLUMN_NAME_CREATE_DATE) == false) {
523 values.put(NotePad.Notes.COLUMN_NAME_CREATE_DATE, now);
528 if (values.containsKey(NotePad.Notes.COLUMN_NAME_MODIFICATION_DATE) == false) {
529 values.put(NotePad.Notes.COLUMN_NAME_MODIFICATION_DATE, now);
533 if (values.containsKey(NotePad.Notes.COLUMN_NAME_TITLE) == false) {
535 values.put(NotePad.Notes.COLUMN_NAME_TITLE, r.getString(android.R.string.untitled));
539 if (values.containsKey(NotePad.Notes.COLUMN_NAME_NOTE) == false) {
540 values.put(NotePad.Notes.COLUMN_NAME_NOTE, "");
548 NotePad.Notes.TABLE_NAME, // The table to insert into.
549 NotePad.Notes.COLUMN_NAME_NOTE, // A hack, SQLite sets this column value to null
558 Uri noteUri = ContentUris.withAppendedId(NotePad.Notes.CONTENT_ID_URI_BASE, rowId);
594 // If the incoming pattern matches the general pattern for notes, does a delete
596 case NOTES:
598 NotePad.Notes.TABLE_NAME, // The database table name
613 NotePad.Notes._ID + // The ID column name
616 get(NotePad.Notes.NOTE_ID_PATH_POSITION)
627 NotePad.Notes.TABLE_NAME, // The database table name.
679 // If the incoming URI matches the general notes pattern, does the update based on
681 case NOTES:
685 NotePad.Notes.TABLE_NAME, // The database table name.
696 String noteId = uri.getPathSegments().get(NotePad.Notes.NOTE_ID_PATH_POSITION);
703 NotePad.Notes._ID + // The ID column name
706 get(NotePad.Notes.NOTE_ID_PATH_POSITION)
718 NotePad.Notes.TABLE_NAME, // The database table name.