Package org.apache.solr.common.cloud
Class ZkNodeProps
- java.lang.Object
- 
- org.apache.solr.common.cloud.ZkNodeProps
 
- 
- All Implemented Interfaces:
- MapSerializable,- MapWriter,- NavigableObject,- org.noggit.JSONWriter.Writable
 - Direct Known Subclasses:
- DocCollection,- Replica,- RoutingRule,- Slice
 
 public class ZkNodeProps extends Object implements MapWriter ZkNodeProps contains generic immutable properties.
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from interface org.apache.solr.common.MapWriterMapWriter.EntryWriter
 
- 
 - 
Constructor SummaryConstructors Constructor Description ZkNodeProps(String... keyVals)Constructor that populates from an array of Strings in form key1, value1, key2, value2, ..., keyN, valueNZkNodeProps(Map<String,Object> propMap)Construct ZKNodeProps from map.ZkNodeProps(MapWriter mw)
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description booleancontainsKey(String key)Check if property key exists.booleanequals(Object that)static ZkNodePropsfromKeyVals(Object... keyVals)Deprecated.Objectget(String key)booleangetBool(String key, boolean b)IntegergetInt(String key, Integer def)Get a string property value.Map<String,Object>getProperties()Get all properties as map.StringgetStr(String key)Get a string property value.StringgetStr(String key, String def)Get a string property value.inthashCode()Set<String>keySet()Get property keys.static ZkNodePropsload(byte[] bytes)Create Replica from json string that is typically stored in zookeeper.ZkNodePropsplus(String key, Object val)ZkNodePropsplus(Map<String,Object> newVals)Map<String,Object>shallowCopy()Returns a shallow writable copy of the propertiesStringtoString()voidwriteMap(MapWriter.EntryWriter ew)- 
Methods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, wait, wait, wait
 - 
Methods inherited from interface org.apache.solr.common.NavigableObject_forEachEntry, _forEachEntry, _forEachEntry, _get, _get, _getStr, _getStr, _size
 
- 
 
- 
- 
- 
Method Detail- 
pluspublic ZkNodeProps plus(String key, Object val) 
 - 
pluspublic ZkNodeProps plus(Map<String,Object> newVals) 
 - 
fromKeyVals@Deprecated(since="9.0.0") public static ZkNodeProps fromKeyVals(Object... keyVals) Deprecated.
 - 
shallowCopypublic Map<String,Object> shallowCopy() Returns a shallow writable copy of the properties
 - 
loadpublic static ZkNodeProps load(byte[] bytes) Create Replica from json string that is typically stored in zookeeper.
 - 
containsKeypublic boolean containsKey(String key) Check if property key exists.
 - 
getBoolpublic boolean getBool(String key, boolean b) 
 - 
writeMappublic void writeMap(MapWriter.EntryWriter ew) throws IOException - Specified by:
- writeMapin interface- MapWriter
- Throws:
- IOException
 
 
- 
 
-