@Override
    public Object getValue(String key) {
        if(isKeyNotValid(key))
            throw new IllegalArgumentException();

        Object value = null;
        
        if(jsonNode != null && jsonNode.key.equals(key)) {
            if(jsonNode instanceof JsonObject ||
                    jsonNode instanceof JsonArrayNode)
                value = jsonNode;
            else
                value = jsonNode.getValue(key);
        }

        if(value == null && jsonNode != null)
            value = jsonNode.getValue(key);

        if(value == null && tail != null)
            value = tail.getValue(key);
        
        return value;
    }