APISonar


org.odk.collect.android.provider.FormsProviderAPI.FormsColumns.DATE

> org > odk > collect > android > provider > FormsProviderAPI > FormsColumns > DATE
org APIs odk APIs collect APIs android APIs provider APIs FormsProviderAPI APIs FormsColumns APIs DATE APIs

Example 1
private void setupAdapter() {
        String[] data = {
            FormsColumns.DISPLAY_NAME, FormsColumns.JR_VERSION,
            FormsColumns.DATE, FormsColumns.JR_FORM_ID};
        int[] view = {R.id.form_title, R.id.form_subtitle, R.id.form_subtitle2};

        listAdapter = new FormListAdapter(
                getListView(), FormsColumns.JR_VERSION, getActivity(),
                R.layout.form_chooser_list_item_multiple_choice, null, data, view);
        setListAdapter(listAdapter);
        checkPreviouslyCheckedItems();
    }
Example 2
private void setupTestFormsDatabase() {
        ContentValues values = new ContentValues();
        values.put(FormsColumns.JRCACHE_FILE_PATH, Collect.ODK_ROOT + "/.cache/3a76a386464925b6f3e53422673dfe3c.formdef");
        values.put(FormsColumns.JR_FORM_ID, "jrFormId");
        values.put(FormsColumns.FORM_MEDIA_PATH, Collect.FORMS_PATH + "/testFile1-media");
        values.put(FormsColumns.DATE, "1487077903756");
        values.put(FormsColumns.DISPLAY_NAME, "displayName");
        values.put(FormsColumns.FORM_FILE_PATH, Collect.FORMS_PATH + "/testFile1.xml");
        Collect.getInstance().getContentResolver()
                .insert(FormsColumns.CONTENT_URI, values);

        assertEquals(1, getFormsCount());
    }