1 /* ownCloud Android client application 
   2  *   Copyright (C) 2011  Bartek Przybylski 
   4  *   This program is free software: you can redistribute it and/or modify 
   5  *   it under the terms of the GNU General Public License as published by 
   6  *   the Free Software Foundation, either version 3 of the License, or 
   7  *   (at your option) any later version. 
   9  *   This program is distributed in the hope that it will be useful, 
  10  *   but WITHOUT ANY WARRANTY; without even the implied warranty of 
  11  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
  12  *   GNU General Public License for more details. 
  14  *   You should have received a copy of the GNU General Public License 
  15  *   along with this program.  If not, see <http://www.gnu.org/licenses/>. 
  18 package eu
.alefzero
.owncloud
.db
; 
  20 import android
.net
.Uri
; 
  21 import android
.provider
.BaseColumns
; 
  24  * Meta-Class that holds various static field information 
  25  * @author Bartek Przybylski 
  28 public class ProviderMeta 
{ 
  30   public static final String AUTHORITY_FILES 
= "org.owncloud"; 
  31   public static final String DB_FILE 
= "owncloud.db"; 
  32   public static final String DB_NAME 
= "filelist"; 
  33   public static final int DB_VERSION 
= 1; 
  35   private ProviderMeta() { } 
  37   static public class ProviderTableMeta 
implements BaseColumns 
{ 
  38     public static final String DB_NAME 
= "filelist"; 
  39     public static final Uri CONTENT_URI 
=   
  40       Uri
.parse("content://" + AUTHORITY_FILES 
+ "/"); 
  41     public static final Uri CONTENT_URI_FILE 
= 
  42       Uri
.parse("content://" + AUTHORITY_FILES 
+ "/file"); 
  43     public static final Uri CONTENT_URI_DIR 
= 
  44       Uri
.parse("content://" + AUTHORITY_FILES 
+ "/dir"); 
  46     public static final String CONTENT_TYPE 
= 
  47       "vnd.android.cursor.dir/vnd.owncloud.file"; 
  48     public static final String CONTENT_TYPE_ITEM 
= 
  49       "vnd.android.cursor.item/vnd.owncloud.file"; 
  51     public static final String FILE_PARENT 
= "parent"; 
  52     public static final String FILE_NAME 
= "filename"; 
  53     public static final String FILE_CREATION 
= "created"; 
  54     public static final String FILE_MODIFIED 
= "modified"; 
  55     public static final String FILE_CONTENT_LENGTH 
= "content_length"; 
  56     public static final String FILE_CONTENT_TYPE 
= "content_type"; 
  57     public static final String FILE_STORAGE_PATH 
= "media_path"; 
  58     public static final String FILE_PATH 
= "path"; 
  59     public static final String FILE_ACCOUNT_OWNER 
= "file_owner"; 
  61     public static final String DEFAULT_SORT_ORDER 
= FILE_NAME 
+ " asc";