public class VagrantProperties extends Object implements com.oracle.bedrock.Option.Collector<VagrantProperty,VagrantProperties>
Collector of VagrantPropertys.
Copyright (c) 2016. All Rights Reserved. Oracle Corporation.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
| Constructor and Description |
|---|
VagrantProperties()
Constructs an empty
VagrantProperties. |
VagrantProperties(Map<String,String> properties)
Constructs a
VagrantProperties with properties based on a
Map of name-value pairs. |
VagrantProperties(Properties properties)
Constructs a
VagrantProperties based on a standard
Properties representation. |
VagrantProperties(VagrantProperties vagrantProperties)
Constructs a
VagrantProperties based on the properties defined
in another VagrantProperties. |
VagrantProperties(VagrantProperty... properties)
Constructs a
VagrantProperties based on the properties defined
in another VagrantProperties. |
| Modifier and Type | Method and Description |
|---|---|
VagrantProperties |
add(VagrantProperty... properties)
Adds the specified
VagrantProperty to the VagrantProperties, returning a new
VagrantProperties containing the VagrantProperty. |
VagrantProperties |
addAll(Map<String,Object> properties)
Adds all of the specified properties represented as a
Map of name-value pairs
as individual VagrantPropertys, returning a new VagrantProperties. |
VagrantProperties |
addAll(VagrantProperties properties)
|
VagrantProperties |
addIfAbsent(VagrantProperty property)
Adds the specified
VagrantProperty to the VagrantProperties, returning a new
VagrantProperties containing the VagrantProperty
(if and only if a VagrantProperty with the same name doesn't already exist). |
boolean |
contains(String propertyName)
Determines if the
VagrantProperties contains a VagrantProperty
with the specified name. |
boolean |
equals(Object o) |
VagrantProperty |
get(String propertyName)
Obtains the
VagrantProperty with the specified name, returning null if
one is not found. |
<O> Iterable<O> |
getInstancesOf(Class<O> requiredClass) |
Object |
getProperty(String name)
Obtains the current value of the specified
VagrantProperty. |
int |
hashCode() |
boolean |
isEmpty()
Determines if the
VagrantProperties is empty (contains no VagrantPropertys) |
Iterator<VagrantProperty> |
iterator() |
VagrantProperties |
remove(String propertyName)
Removes the specified
VagrantProperty named property from the VagrantProperties, returning a new
VagrantProperties without the said VagrantProperty. |
int |
size()
Obtains the number of
VagrantPropertys contained
by the VagrantProperties. |
VagrantProperties |
with(VagrantProperty property) |
VagrantProperties |
without(VagrantProperty property) |
void |
write(PrintWriter writer,
String sPrefix,
String sPad)
Writes the
VagrantProperties to the specified PrintWriter. |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitforEach, spliterator@OptionsByType.Default public VagrantProperties()
VagrantProperties.public VagrantProperties(Map<String,String> properties)
VagrantProperties with properties based on a
Map of name-value pairs.properties - the Map of properties to use as the basis for
the VagrantPropertiespublic VagrantProperties(Properties properties)
VagrantProperties based on a standard
Properties representation.properties - the Properties to use as the basis for the
VagrantPropertiespublic VagrantProperties(VagrantProperties vagrantProperties)
VagrantProperties based on the properties defined
in another VagrantProperties.vagrantProperties - the VagrantProperties on which to base
the new VagrantPropertiespublic VagrantProperties(VagrantProperty... properties)
VagrantProperties based on the properties defined
in another VagrantProperties.properties - the VagrantProperties on which to base
the new VagrantPropertiespublic int size()
VagrantPropertys contained
by the VagrantProperties.VagrantPropertyspublic boolean isEmpty()
VagrantProperties is empty (contains no VagrantPropertys)true if the VagrantProperties is empty, false otherwisepublic VagrantProperties add(VagrantProperty... properties)
VagrantProperty to the VagrantProperties, returning a new
VagrantProperties containing the VagrantProperty.properties - the VagrantPropertys to addVagrantProperties instance, including
the existing VagrantPropertys and the new VagrantPropertypublic VagrantProperties addIfAbsent(VagrantProperty property)
VagrantProperty to the VagrantProperties, returning a new
VagrantProperties containing the VagrantProperty
(if and only if a VagrantProperty with the same name doesn't already exist).property - the VagrantProperty to addVagrantProperties instance, including the existing VagrantPropertys and the new VagrantPropertypublic VagrantProperties remove(String propertyName)
VagrantProperty named property from the VagrantProperties, returning a new
VagrantProperties without the said VagrantProperty.propertyName - the VagrantProperty to removeVagrantProperties instance, excluding the specified VagrantPropertypublic VagrantProperties addAll(Map<String,Object> properties)
Map of name-value pairs
as individual VagrantPropertys, returning a new VagrantProperties.properties - the Map of propertiesVagrantPropertiespublic VagrantProperties addAll(VagrantProperties properties)
properties - the VagrantPropertiesVagrantPropertiespublic boolean contains(String propertyName)
VagrantProperties contains a VagrantProperty
with the specified name.propertyName - the name of the VagrantPropertytrue if the VagrantProperties contains a VagrantProperty
with the specified name, false otherwisepublic VagrantProperty get(String propertyName)
VagrantProperty with the specified name, returning null if
one is not found.propertyName - the name of the desired VagrantPropertyVagrantProperty of null if not definedpublic Object getProperty(String name)
VagrantProperty. If the property has
a value specified, that value will be used. If the property is unknown,
null will be returned.name - the name of the propertyObjectpublic VagrantProperties with(VagrantProperty property)
with in interface com.oracle.bedrock.Option.Collector<VagrantProperty,VagrantProperties>public VagrantProperties without(VagrantProperty property)
without in interface com.oracle.bedrock.Option.Collector<VagrantProperty,VagrantProperties>public <O> Iterable<O> getInstancesOf(Class<O> requiredClass)
getInstancesOf in interface com.oracle.bedrock.Option.Collector<VagrantProperty,VagrantProperties>public Iterator<VagrantProperty> iterator()
iterator in interface Iterable<VagrantProperty>public void write(PrintWriter writer, String sPrefix, String sPad)
VagrantProperties to the specified PrintWriter.writer - the PrintWritersPrefix - the prefix for each propertysPad - the padding for each propertyCopyright © 2017. All rights reserved.