'Adds an rdf value to a collection.
Adds an rdf value to a collection. Does not require that the collection be
open. NOTE: The caller is responsible for ensuring that the collection
exists and is of the correct type.
Args:
collection_urn: The urn of the collection to add to.
token: The database access token to write with.
rdf_value: The rdf value to add to the collection. If this value is not
GrrMessage, it will be wrapped into GrrMessage (later when
collection is iterated, this value will still be returned wrapped
in GrrMessage).
timestamp: The timestamp (in microseconds) to store the rdf value
at. Defaults to the current time.
suffix: A \'fractional timestamp\' suffix to reduce the chance of
collisions. Defaults to a random number.
mutation_pool: An optional MutationPool object to write to. If not given,
the data_store is used directly.
**kwargs: Keyword arguments to pass through to the underlying database
call.
Returns:
The pair (timestamp, suffix) which identifies the value within the
collection.
Raises:
ValueError: rdf_value has unexpected type.'

@classmethod
def StaticAdd(cls, collection_urn, token, rdf_value, timestamp=None, suffix=None, mutation_pool=None, **kwargs):

    if (rdf_value is None):
        raise ValueError("Can't    add    None    to    MultiTypeCollection")
    if (not isinstance(rdf_value, rdf_flows.GrrMessage)):
        rdf_value = rdf_flows.GrrMessage(payload=rdf_value)
    value_type = (rdf_value.args_rdf_name or rdf_flows.GrrMessage.__name__)
    subpath = collection_urn.Add(value_type)
    sequential_collection.GrrMessageCollection.StaticAdd(subpath, token, rdf_value, timestamp=timestamp, suffix=suffix, mutation_pool=mutation_pool, **kwargs)
    if mutation_pool:
        mutation_pool.Set(collection_urn, ('%s%s' % (cls.VALUE_TYPE_PREFIX, value_type)), 1, timestamp=0, **kwargs)
    else:
        data_store.DB.Set(collection_urn, ('%s%s' % (cls.VALUE_TYPE_PREFIX, value_type)), 1, timestamp=0, token=token, **kwargs)
