org.gcube.data.trees.generators
Class StructuralTemplate.STBuilder

java.lang.Object
  extended by org.gcube.data.trees.generators.StructuralTemplate.STBuilder
Enclosing class:
StructuralTemplate

public static class StructuralTemplate.STBuilder
extends Object

Builds StructuralTemplates.

Author:
Fabio Simeoni

Constructor Summary
StructuralTemplate.STBuilder()
           
 
Method Summary
 StructuralTemplate build()
          Builds the template.
 StructuralTemplate.STBuilder deep(int depth)
          Sets the depth on the template.
 StructuralTemplate.STBuilder inSource(String id)
          Sets a source identifier on the template.
 StructuralTemplate totalling(int size)
          Sets an approximate size in kilobyte for the tree
 StructuralTemplate.STBuilder wide(int w)
          Sets the width on the template.
 StructuralTemplate.STBuilder withAttributes(int max)
          Sets the maximum number of attributes on the template.
 StructuralTemplate.STBuilder withIds()
          Sets the generation of node identifiers on the template.
 StructuralTemplate.STBuilder withValuesOf(int max)
          Sets the maximum size of leaf values on the template.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StructuralTemplate.STBuilder

public StructuralTemplate.STBuilder()
Method Detail

inSource

public StructuralTemplate.STBuilder inSource(String id)
Sets a source identifier on the template.

Parameters:
id - the source identifier
Returns:
the template

wide

public StructuralTemplate.STBuilder wide(int w)
Sets the width on the template.

Parameters:
w - the width
Returns:
this builder

deep

public StructuralTemplate.STBuilder deep(int depth)
Sets the depth on the template.

Parameters:
depth - the depth
Returns:
this builder

totalling

public StructuralTemplate totalling(int size)
Sets an approximate size in kilobyte for the tree

Parameters:
size - the size
Returns:
this builder

withAttributes

public StructuralTemplate.STBuilder withAttributes(int max)
Sets the maximum number of attributes on the template.

Parameters:
max - the maximum number of attributes
Returns:
this builder

withValuesOf

public StructuralTemplate.STBuilder withValuesOf(int max)
Sets the maximum size of leaf values on the template.

Parameters:
max - the maximum size of leaf values
Returns:
this builder

withIds

public StructuralTemplate.STBuilder withIds()
Sets the generation of node identifiers on the template.

Returns:
this builder

build

public StructuralTemplate build()
Builds the template.

Returns:
the template


Copyright © 2013. All Rights Reserved.