Ejemplo n.º 1
0
 public void setQuery(string ProjQueryName)
 {                
     var xpath = String.Format("query[@name='{0}']", ProjQueryName);
     _query = new SchemaQueryType();
     _query = ProjectFlx.Schema.SchemaQueryType.Deserialize(_catalog.SelectSingleNode(xpath).OuterXml);
     _query.project = _project;
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Get a SchemaQueryType for quickly building a query to execute
        /// </summary>
        /// <param name="QueryName"></param>
        /// <param name="Action"></param>
        /// <param name="CommandName"></param>
        /// <returns></returns>
        public static SchemaQueryType Create(string QueryName, actionType CommandType, string CommandName, string CommandText = null)
        {
            var query = new ProjectFlx.Schema.SchemaQueryType();
            query.name = QueryName;
            query.command = new ProjectFlx.Schema.command();
            query.command.name.Text.Add(CommandName);
            query.command.action = CommandType;

            if (!String.IsNullOrEmpty(CommandText))
            {
                query.command.text = new mixedContent();
                query.command.text.Text = new List<string>();
                query.command.text.Text.Add(CommandText);
                query.command.type = new commandType();
                query.command.type = commandType.Select;
            }

            query.fields = new List<ProjectFlx.Schema.field>();
            query.parameters = new ProjectFlx.Schema.parameters();

            return query;
        }
Ejemplo n.º 3
0
 public void setQuery(string ProjQueryName)
 {
     var xpath = String.Format("query[@name='{0}']", ProjQueryName);
     _query = ProjectFlx.Schema.SchemaQueryType.Deserialize(_catalog.SelectSingleNode(xpath).OuterXml);
     _query.project = _project;
 }
Ejemplo n.º 4
0
        /// <summary>
        /// Get a SchemaQueryType for quickly building a query to execute
        /// </summary>
        /// <param name="QueryName"></param>
        /// <param name="Action"></param>
        /// <param name="CommandName"></param>
        /// <returns></returns>
        public static SchemaQueryType Create(string QueryName, actionType CommandType, string CommandName, string CommandText = null)
        {
            var query = new ProjectFlx.Schema.SchemaQueryType();
            query.name = QueryName;
            query.command = new ProjectFlx.Schema.command();
            query.command.name.Text.Add(CommandName);
            query.command.action = CommandType;

            if (!String.IsNullOrEmpty(CommandText))
            {
                query.command.text = new mixedContent();
                query.command.text.Text = new List<string>();
                query.command.text.Text.Add(CommandText);
                query.command.type = new commandType();
                query.command.type = commandType.Select;
            }

            query.fields = new List<ProjectFlx.Schema.field>();
            query.parameters = new ProjectFlx.Schema.parameters();

            return query;
        }