Beispiel #1
0
        static void Main(string[] args)
        {
            MessageMaker mm  = new MessageMaker();
            Message      msg = mm.makeMessage("fromFoo", "toBar");

            Utilities.showMessage(msg);
            Console.Write("\n\n");
        }
Beispiel #2
0
        //----< Create Message for Edit Request >----------------------------
        private Message ProcessEdit()
        {
            MessageMaker maker = new MessageMaker();
            Message      msg   = maker.makeEditRequest(
                localUrl, remoteUrl, clientCount
                );

            return(msg);
        }
Beispiel #3
0
        //----< Create Message for DB Display Request >----------------------
        private Message ProcessShowDB(XElement showDB)
        {
            MessageMaker maker = new MessageMaker();
            Message      msg   = maker.makeDisplayRequest(
                localUrl,
                remoteUrl
                );

            return(msg);
        }
Beispiel #4
0
        //----< Create Message for Restore Request >-------------------------
        private Message ProcessRestore(XElement persist)
        {
            XElement file     = persist.Element("Filename");
            string   filename = file.Value.ToString();

            MessageMaker maker = new MessageMaker();
            Message      msg   = maker.makeRestoreRequest(
                localUrl, remoteUrl, filename, clientCount
                );

            return(msg);
        }
Beispiel #5
0
        //----< Create Message for Query Request >---------------------------
        private Message ProcessQuery(XElement query)
        {
            int    type  = int.Parse(query.Element("Type").Value.ToString());
            string param = query.Element("String").Value.ToString();

            MessageMaker maker = new MessageMaker();
            Message      msg   = maker.makeQuery(
                localUrl,
                remoteUrl,
                type, param
                );

            return(msg);
        }
Beispiel #6
0
 //----< Default Constructor >--------------------------------------------
 Server()
 {
     SetupDB();
     maker  = new MessageMaker();
     parser = new MessageParser();
 }