/* Copyright (c) 2000-2006 ActiveState Software Inc.
   See the file LICENSE.txt for licensing information. */

#include "nsISupports.idl"
#include "nsITreeView.idl"


[scriptable, uuid(27DE09DC-4C99-4ab1-8130-E504123EE9E1)]
interface koICGIVariablesView : nsITreeView {
    // An tree view for CGI Variables data.

    // Clear the list of find results.
    void Clear();

    // Add a single find result.
    void AddVariable(in string type,
                   in wstring name,
                   in wstring value);
    void removeRow(in unsigned long index);
    long haveVariable(in string type, in wstring name);
    
    // Extract part of the find result data at a specific index.
    wstring GetType(in unsigned long index);
    wstring GetName(in unsigned long index);
    wstring GetValue(in unsigned long index);

    // Sort the find result data by a certain key (this key typically matches
    // the <treecol id=.../>  id's).
    void Sort(in string sortBy);
                                                   
    void setVariables(in string type, in wstring env);
    wstring getVariables(in string type);
};

[scriptable, uuid(5FF6F4A0-1834-4be8-B674-A92B61EEFCDE)]
interface koIEnvironmentView : nsITreeView {
    // An tree view for CGI Variables data.

    // Clear the list of find results.
    void Clear();

    // Add a single find result.
    void AddVariable(in wstring name, in wstring value);
    long haveVariable(in wstring name);
    void removeRow(in unsigned long index);
    
    // Extract part of the find result data at a specific index.
    wstring GetVariable(in unsigned long index); // return "NAME=Value"
    wstring GetName(in unsigned long index);  
    wstring GetValue(in unsigned long index);

    // Sort the find result data by a certain key (this key typically matches
    // the <treecol id=.../>  id's).
    void Sort(in string sortBy);
                                                   
    void setVariables(in wstring env);
    wstring getVariables();
};
    