Package tigase.util.repository

## Class DataTypes

- java.lang.Object
- - tigase.util.repository.DataTypes

-     public class DataTypes
      extends java.lang.Object

  Created: May 28, 2009 7:39:07 AM
  Author:
    Artur Hefczyc

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `static java.util.Map<java.lang.String,​java.lang.Character>` | `typesMap` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `DataTypes()` |

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static char` | `decodeTypeIdFromName​(java.lang.String name)` |
    `static java.lang.Object` | `decodeValueType​(char typeId, java.lang.String value)` |
    `static java.lang.String` | `encodeTypeIdInName​(java.lang.String name, java.lang.Object value)` |
    `static boolean` | `getProperty​(java.lang.String key, java.lang.Boolean def)` |
    `static char` | `getTypeId​(java.lang.Object instance)` |
    `static void` | `main​(java.lang.String[] args)` |
    `static boolean` | `parseBool​(java.lang.String val)` |
    `static <T extends java.lang.Number> T` | `parseNum​(java.lang.String num, java.lang.Class<T> cls, T def)` |
    `static int` | `parseSizeInt​(java.lang.String size, int def)` |
    `static java.lang.String` | `stripNameFromTypeId​(java.lang.String name)` |
    `static java.lang.String` | `valueToString​(java.lang.Object value)` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### typesMap

          public static final java.util.Map<java.lang.String,​java.lang.Character> typesMap

  - ### Constructor Detail

    - #### DataTypes

          public DataTypes()

  - ### Method Detail

    - #### decodeTypeIdFromName

          public static char decodeTypeIdFromName​(java.lang.String name)

    - #### decodeValueType

          public static java.lang.Object decodeValueType​(char typeId,
                                                         java.lang.String value)
                                                  throws java.lang.IllegalArgumentException

      Throws:
        `java.lang.IllegalArgumentException`

    - #### encodeTypeIdInName

          public static java.lang.String encodeTypeIdInName​(java.lang.String name,
                                                            java.lang.Object value)

    - #### getProperty

          public static boolean getProperty​(java.lang.String key,
                                            java.lang.Boolean def)

    - #### getTypeId

          public static char getTypeId​(java.lang.Object instance)

    - #### main

          public static void main​(java.lang.String[] args)

    - #### parseBool

          public static boolean parseBool​(java.lang.String val)

    - #### parseNum

          public static <T extends java.lang.Number> T parseNum​(java.lang.String num,
                                                                java.lang.Class<T> cls,
                                                                T def)

    - #### parseSizeInt

          public static int parseSizeInt​(java.lang.String size,
                                         int def)

    - #### stripNameFromTypeId

          public static java.lang.String stripNameFromTypeId​(java.lang.String name)

    - #### valueToString

          public static java.lang.String valueToString​(java.lang.Object value)