public override StringValue serialize(Env env) { ArrayValue array = new ArrayValueImpl(); StringValue objStr = env.createString("obj"); StringValue valueStr = env.createString("inf"); ObjectEntry entry = _head; while (entry != null) { ArrayValue inner = new ArrayValueImpl(); inner.put(objStr, entry.getObject()); inner.put(valueStr, entry.getValue()); array.append(inner); entry = entry.getNext(); } string str = VariableModule.serialize(env, array); return(env.createString(str)); }
public void addAll(Env env, SplObjectStorage storage) { ObjectEntry entry = storage._head; while (entry != null) { attachImpl(env, entry.getHash(), entry.getObject(), entry.getValue()); entry = entry.getNext(); } }