T - The extensible type itself.public abstract class Extensible<T extends Extensible<T>> extends Object implements JsonSerializable
| Modifier | Constructor and Description |
|---|---|
protected |
Extensible(Map<String,Object> members)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
Map<String,Object> |
asJson() |
abstract T |
copy()
Copy this item.
|
Object |
get(String name)
Get the member, or null if not present.
|
protected abstract Set<String> |
getKnownMembers()
Returns the 'known' keys, that are specially treated by Rollbar
|
Map<String,Object> |
getMembers()
Get a copy of the members.
|
Set<String> |
keys(boolean withoutKnownMembers)
Get the keys in this extensible
|
T |
put(String name,
Object value)
Sets the member.
|
protected void |
putKnown(String name,
Object value)
MUTATING.
|
protected abstract Set<String> getKnownMembers()
public Object get(String name)
name - the member namepublic abstract T copy()
public T put(String name, Object value) throws IllegalArgumentException
name - the member name to set.value - the value to set.IllegalArgumentExceptionprotected void putKnown(String name, Object value)
name - the keyvalue - the valuepublic Set<String> keys(boolean withoutKnownMembers)
withoutKnownMembers - true if you want to leave out known memberspublic Map<String,Object> getMembers()
public Map<String,Object> asJson()
asJson in interface JsonSerializableCopyright © 2016. All rights reserved.