Class Attribute<T>
- java.lang.Object
-
- com.jfrog.bintray.client.api.details.Attribute<T>
-
public class Attribute<T> extends Object
This class represents an attribute (version or package) NOTE: when serializing this class use getObjectMapper to obtain a suitable mapper for this class
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Attribute.Type
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
static List<Attribute>
getAttributeListFromJson(InputStream inputStream)
static String
getJsonFromAttributeList(List<Attribute> attributeDetails)
Produces a json from a list of attributesString
getName()
static com.fasterxml.jackson.databind.ObjectMapper
getObjectMapper()
Attribute.Type
getType()
List<T>
getValues()
int
hashCode()
String
toString()
-
-
-
Constructor Detail
-
Attribute
@SafeVarargs public Attribute(String name, T... values)
-
Attribute
@SafeVarargs public Attribute(String name, Attribute.Type type, T... values)
-
Attribute
public Attribute(String name, Attribute.Type type, List<T> values)
-
-
Method Detail
-
getObjectMapper
public static com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
-
getJsonFromAttributeList
public static String getJsonFromAttributeList(List<Attribute> attributeDetails) throws IOException
Produces a json from a list of attributes- Parameters:
attributeDetails
- List of attributes to serialize- Returns:
- A string representing the json
- Throws:
IOException
-
getAttributeListFromJson
public static List<Attribute> getAttributeListFromJson(InputStream inputStream) throws IOException
- Throws:
IOException
-
getName
public String getName()
-
getType
public Attribute.Type getType()
-
-