public class VagrantProperty extends Object implements com.oracle.bedrock.Option.Collectable
Collectable Option representing a Vagrant Property, consisting
of a name and value.
Values of a VagrantProperty may be more than simple Strings. For example,
if they are an Iterator, the value of a Vagrant Property will be the next
value taken from the Iterator.
Copyright (c) 2016. All Rights Reserved. Oracle Corporation.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
VagrantProperties| Modifier and Type | Method and Description |
|---|---|
Class<VagrantProperties> |
getCollectorClass() |
String |
getName()
Obtains the name of the
VagrantProperty. |
Object |
getValue()
Obtains the value of the
VagrantProperty. |
static VagrantProperty |
of(String name,
Iterator iterator)
Constructs a
VagrantProperty. |
static VagrantProperty |
of(String name,
Object object)
Constructs a
VagrantProperty. |
static VagrantProperty |
of(String name,
String value)
Constructs a
VagrantProperty. |
String |
toString() |
void |
write(PrintWriter writer,
String sPrefix,
String sPad)
Writes the
VagrantProperty to the specified PrintWriter. |
public static VagrantProperty of(String name, String value)
VagrantProperty.name - the name of the VagrantPropertyvalue - the value of the VagrantPropertyVagrantPropertypublic static VagrantProperty of(String name, Iterator iterator)
VagrantProperty.name - the name of the VagrantPropertyiterator - the iterator that can provide values for the VagrantPropertyVagrantPropertypublic static VagrantProperty of(String name, Object object)
VagrantProperty.name - the name of the VagrantPropertyobject - the values for the VagrantPropertyVagrantPropertypublic String getName()
VagrantProperty.VagrantPropertypublic Object getValue()
VagrantProperty.VagrantPropertypublic void write(PrintWriter writer, String sPrefix, String sPad)
VagrantProperty to the specified PrintWriter.writer - the PrintWritersPrefix - the prefix for propertysPad - the padding for the propertypublic Class<VagrantProperties> getCollectorClass()
getCollectorClass in interface com.oracle.bedrock.Option.CollectableCopyright © 2017. All rights reserved.