Code example for LinkedList

Methods: getFirst

0
    /** 
     * gets the base object 
     * @return The base object 
     */ 
    public DBObject get(){ 
        return _stack.getFirst();
    } 
 
    /** 
     * returns true if no key/value was inserted into base object 
     * @return True if empty 
     */ 
    public boolean isEmpty(){ 
        return ((BasicDBObject) _stack.getFirst()).size() == 0;
    } 
 
    private DBObject _cur(){ 
        return _stack.getLast();
    } 
 
    private final LinkedList<DBObject> _stack;