Description Usage Arguments Value See Also Examples
Create a mongo.symbol object for appending to a buffer with
mongo.bson.buffer.append()
or for embedding in a list such
that mongo.bson.buffer.append.list()
will properly insert a
symbol value into the mongo.bson.buffer object.
1 | mongo.symbol.create(value)
|
value |
(string) The value of the symbol |
a mongo.symbol object
mongo.symbol,
mongo.bson.buffer.append
,
mongo.bson.buffer.append.list
,
mongo.bson.buffer,
mongo.bson.
1 2 3 4 5 6 7 8 9 10 11 12 13 | buf <- mongo.bson.buffer.create()
sym <- mongo.symbol.create("Alpha")
mongo.bson.buffer.append(buf, "A", sym)
lst <- list(s1 = sym, One = 1)
mongo.bson.buffer.append.list(buf, "listWsym", lst)
mongo.bson.buffer.append.symbol(buf, "D", "Delta")
b <- mongo.bson.from.buffer(buf)
# the above will create a mongo.bson object of the following form:
# { "A": (SYMBOL) "Alpha",
# "listWsym" : { "a1" : (SYMBOL) "Aplha",
# "One" : 1 },
# "D" : (SYMBOL) "Delta" }
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.