Пример #1
0
 // create a new doc object around an existing doc in the db
 internal GlDoc(GlDocSet parent_docset, Guid doc_guid)
 {
     _DocUID       = doc_guid;
     _ParentDocSet = parent_docset;
     _DocNodeRef   = GlobalsDocDB.ActiveConnection().CreateNodeReference(_ParentDocSet.Name);
     _DocNodeRef.AppendSubscript(_DocUID.ToString());
 }
Пример #2
0
        // CONSTRUCTORS (internal). Note that GlDoc objects for existing documents
        // are created by the GlDocSet constructor. GlDoc objects for docs being
        // created by the user are created by GlDocSet.CreateNewDoc(). These two
        // GlDocSet methods call these internal constructors for GlDoc.

        // create a doc object for a brand-new doc (does not exist in DB yet)
        internal GlDoc(GlDocSet parent_docset)
        {
            _DocUID       = Guid.NewGuid();
            _ParentDocSet = parent_docset;
            _DocNodeRef   = GlobalsDocDB.ActiveConnection().CreateNodeReference(_ParentDocSet.Name);
            _DocNodeRef.AppendSubscript(_DocUID.ToString());
            _DocNodeRef.Set("GlDoc"); // dummy
        }
Пример #3
0
        public static List <GlDocSet> AllDocSets()
        {
            List <GlDocSet> working_list = new List <GlDocSet>();

            foreach (string ds_name in AllDocSetNames())
            {
                string   err_msg = "";
                GlDocSet new_ds  = CreateDocSet(ds_name, out err_msg);
                if (err_msg == "")
                {
                    working_list.Add(new_ds);
                }
            }
            return(working_list);
        }
Пример #4
0
 public void InitForDocSet(GlDocSet working_docset)
 {
     working_noderef = working_docset.GlNodeRef;
     DisplayForSubscripts();
 }