//   Copyright 2013 Cybozu
//
//   Licensed under the Apache License, Version 2.0 (the "License");
//   you may not use this file except in compliance with the License.
//   You may obtain a copy of the License at
//
//       http://www.apache.org/licenses/LICENSE-2.0
//
//   Unless required by applicable law or agreed to in writing, software
//   distributed under the License is distributed on an "AS IS" BASIS,
//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//   See the License for the specific language governing permissions and
//   limitations under the License.

package com.cybozu.kintone.database;

/**
 * Defines the field types which kintone official api provides.
 * 
 */
public enum FieldType {

    SINGLE_LINE_TEXT, 
    NUMBER, 
    CALC, 
    MULTI_LINE_TEXT, 
    RICH_TEXT, 
    CHECK_BOX, 
    RADIO_BUTTON, 
    DROP_DOWN, 
    MULTI_SELECT, 
    FILE, 
    DATE, 
    TIME, 
    DATETIME, 
    USER_SELECT, 
    LINK, 
    CATEGORY, 
    STATUS, 
    RECORD_NUMBER, 
    CREATOR, 
    CREATED_TIME, 
    MODIFIER, 
    UPDATED_TIME, 
    STATUS_ASSIGNEE, 
    SUBTABLE,
    ORGANIZATION_SELECT,
    GROUP_SELECT,
    __REVISION__,
    __ID__;

    public static FieldType getEnum(String str) {
        FieldType[] values = FieldType.values();

        for (FieldType value : values) {
            if (str.equals(value.toString())) {
                return value;
            }
        }
        return null;
    }
}

@@ -775,25 +775,24 @@
 E_LINE_TEXT,
- 
 %0D%0A    NUMBER
@@ -788,25 +788,24 @@
 %0A    NUMBER,
- 
 %0D%0A    CALC, 
@@ -803,17 +803,16 @@
    CALC,
- 
 %0D%0A    MU
@@ -821,25 +821,24 @@
 I_LINE_TEXT,
- 
 %0D%0A    RICH_T
@@ -841,17 +841,16 @@
 CH_TEXT,
- 
 %0D%0A    CH
@@ -857,17 +857,16 @@
 ECK_BOX,
- 
 %0D%0A    RA
@@ -876,17 +876,16 @@
 _BUTTON,
- 
 %0D%0A    DR
@@ -892,17 +892,16 @@
 OP_DOWN,
- 
 %0D%0A    MU
@@ -907,25 +907,24 @@
 ULTI_SELECT,
- 
 %0D%0A    FILE, 
@@ -922,17 +922,16 @@
    FILE,
- 
 %0D%0A    DA
@@ -933,17 +933,16 @@
    DATE,
- 
 %0D%0A    TI
@@ -940,25 +940,24 @@
 ,%0D%0A    TIME,
- 
 %0D%0A    DATETI
@@ -955,25 +955,24 @@
    DATETIME,
- 
 %0D%0A    USER_S
@@ -977,17 +977,16 @@
 _SELECT,
- 
 %0D%0A    LI
@@ -988,17 +988,16 @@
    LINK,
- 
 %0D%0A    CA
@@ -1003,17 +1003,16 @@
 ATEGORY,
- 
 %0D%0A    ST
@@ -1016,17 +1016,16 @@
  STATUS,
- 
 %0D%0A    RE
@@ -1036,17 +1036,16 @@
 _NUMBER,
- 
 %0D%0A    CR
@@ -1050,17 +1050,16 @@
 CREATOR,
- 
 %0D%0A    CR
@@ -1065,25 +1065,24 @@
 REATED_TIME,
- 
 %0D%0A    MODIFI
@@ -1084,17 +1084,16 @@
 ODIFIER,
- 
 %0D%0A    UP
@@ -1103,17 +1103,16 @@
 ED_TIME,
- 
 %0D%0A    ST
@@ -1125,17 +1125,16 @@
 SSIGNEE,
- 
 %0D%0A    SU

Add ORGANIZATION_SELECT and GROUP_SELECT to fieldtype