public class SchemaBuilder extends Object
| Modifier and Type | Method and Description |
|---|---|
Schema |
build()
Build a new schema from the currently set values
|
SchemaBuilder |
canBeDeleted(boolean canBeDeleted) |
SchemaBuilder |
dataValidator(SchemaValidator schemaValidator) |
SchemaBuilder |
documentation(String documentation) |
SchemaBuilder |
ephemeral(Schema.Allowance ephemeral) |
SchemaBuilder |
metadata(Map<String,String> metadata) |
SchemaBuilder |
name(String name) |
SchemaBuilder |
sequential(Schema.Allowance sequential) |
SchemaBuilder |
watched(Schema.Allowance watched) |
public Schema build()
public SchemaBuilder name(String name)
name - unique name for this schemapublic SchemaBuilder documentation(String documentation)
documentation - user displayable documentation for the schemapublic SchemaBuilder dataValidator(SchemaValidator schemaValidator)
schemaValidator - a data validator - will be used to validate data set for the znodepublic SchemaBuilder ephemeral(Schema.Allowance ephemeral)
ephemeral - whether can, must or cannot be ephemeralpublic SchemaBuilder sequential(Schema.Allowance sequential)
sequential - whether can, must or cannot be sequentialpublic SchemaBuilder watched(Schema.Allowance watched)
watched - whether can, must or cannot be watchedpublic SchemaBuilder canBeDeleted(boolean canBeDeleted)
canBeDeleted - true if znode can be deletedpublic SchemaBuilder metadata(Map<String,String> metadata)
metadata - any field -> value you wantCopyright © 2011–2020 The Apache Software Foundation. All rights reserved.