DataTypeResultSetImpl extends ResultSetColumnImpl implements DataTypeResultSet { @Override public Type getType( final UnitOfWork uow ) throws KException { String value = getObjectProperty( uow, PropertyValueType.STRING, "getDataType", StandardDdlLexicon.DATATYPE_NAME ); if (StringUtils.isBlank( value )) { return Type.DEFAULT_VALUE; } final int index = value.indexOf( ARRAY_SUFFIX ); if (index != -1) { value = value.substring( 0, index ); } final Type result = Type.valueOf( value ); if (result == null) { return Type.DEFAULT_VALUE; } return result; } DataTypeResultSetImpl( final UnitOfWork uow,
                                  final Repository repository,
                                  final String workspacePath ); @Override String getDisplayString( final UnitOfWork transaction ); @Override Type getType( final UnitOfWork uow ); @Override KomodoType getTypeIdentifier( final UnitOfWork uow ); @Override AbstractProcedure getParent( final UnitOfWork transaction ); @Override boolean isArray( final UnitOfWork uow ); @Override final void rename( final UnitOfWork transaction,
                              final String newName ); @Override void setArray( final UnitOfWork uow,
                          final boolean newArrayIndicator ); @Override void setDatatypeName( final UnitOfWork uow,
                                 final String newTypeName ); @Override void setType( final UnitOfWork uow,
                         final Type newType );  }
@Test public void shouldHaveDefaultTypeAfterConstruction() throws Exception { assertThat( this.resultSet.getType( getTransaction() ), is( Type.DEFAULT_VALUE ) ); }