Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| ModeShape Distribution 3.0.0.Beta3
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.infinispan.schematic.internal.schema
Class DocumentTransformer

    java.lang.Object
      org.infinispan.schematic.internal.schema.DocumentTransformer

    public class DocumentTransformer

extends Object

Nested Class Summary
`protected static class` | `DocumentTransformer.Conversion`
`protected static class` | `DocumentTransformer.PropertiesAccessor`
`static class` | `DocumentTransformer.PropertiesTransformer` An implementation of `Document.ValueTransformer` that replaces variables in the field values with values from the system properties.
`protected static interface` | `DocumentTransformer.PropertyAccessor`
`static class` | `DocumentTransformer.SystemPropertiesTransformer` An implementation of `Document.ValueTransformer` that replaces variables in the field values with values from the system properties.
`protected static class` | `DocumentTransformer.SystemPropertyAccessor`

Constructor Summary
`DocumentTransformer()`

Method Summary
`protected static Document` | `convertValuesWithMismatchedTypes(Document original, int level, LinkedList<DocumentTransformer.Conversion> conversions)`
`static Document` | `convertValuesWithMismatchedTypes(Document original, SchemaLibrary.Results results)` Return a copy of the supplied document that contains converted values for all of the fields (including in the nested documents and arrays) that have values that are of the wrong type but can be converted to be of the correct type.
`static String` | `getSubstitutedProperty(String value, DocumentTransformer.PropertyAccessor propertyAccessor)` getSubstitutedProperty is called to perform the property substitution on the value.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DocumentTransformer

    public DocumentTransformer()

Method Detail

### getSubstitutedProperty

    public static String getSubstitutedProperty(String value,
                                                DocumentTransformer.PropertyAccessor propertyAccessor)

  getSubstitutedProperty is called to perform the property substitution on the value.

  Parameters:
    `value` -
    `propertyAccessor` -
  Returns:
    String

### convertValuesWithMismatchedTypes

    public static Document convertValuesWithMismatchedTypes(Document original,
                                                            SchemaLibrary.Results results)

  Return a copy of the supplied document that contains converted values for all of the fields (including in the nested documents and arrays) that have values that are of the wrong type but can be converted to be of the correct type.

  This method does nothing and returns the original document if there are no changes to be made.

  Parameters:
    `original` - the original document that contains fields with mismatched values; may not be null
    `results` - the results of the `JSON Schema validation` and which contains the `type mismatch errors`
  Returns:
    the document with all of the conversions made the its fields and the fields of nested documents, or the original document if there are no conversions to be made; never null

### convertValuesWithMismatchedTypes

    protected static Document convertValuesWithMismatchedTypes(Document original,
                                                               int level,
                                                               LinkedList<DocumentTransformer.Conversion> conversions)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| ModeShape Distribution 3.0.0.Beta3
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008-2012 JBoss, a division of Red Hat. All Rights Reserved.