Package com.dragome.model

Source Code of com.dragome.model.ArrayListIteratorTransformer

/*******************************************************************************
* Copyright (c) 2011-2014 Fernando Petrola
*
* This file is part of Dragome SDK.
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the GNU Public License v3.0
* which accompanies this distribution, and is available at
* http://www.gnu.org/licenses/gpl.html
******************************************************************************/
package com.dragome.model;

import flexjson.JSONContext;
import flexjson.TypeContext;
import flexjson.transformer.AbstractTransformer;

public class ArrayListIteratorTransformer extends AbstractTransformer
{
  public void transform(Object object)
  {
    int identityHashCode= System.identityHashCode(object);

    JSONContext context= getContext();

    TypeContext typeContext= context.writeOpenObject();
    context.writeName("@id");
    context.write("" + identityHashCode);

    context.writeComma();
    context.writeName("class");
    context.writeQuoted(NullIterator.class.getName());

    context.writeCloseObject();
  }
}
TOP

Related Classes of com.dragome.model.ArrayListIteratorTransformer

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.