Beispiel #1
0
        public void TestMethod1()
        {
            List <Node> nodes = new List <Node>();

            NodeGenerator.Generate(5000, nodes);

            BlockManager bm = new BlockManager();

            bm.Build(nodes);        // vystav strukturu
            bm.LoadMemoryBlock(49); //nacti memory block 5
            //     bm.TESTING_METHOD_REMOVE_AFTER_TESTING();

            // TODO: hledani (Dodelat binar, interpolacni)
            // TODO: odstranovani - kontanta jako prazdne misto ?
            // TODO: rebuild pri pridavani ?

            int a = 0;

            bm.SaveMemoryBlock();

            bm.LoadMemoryBlock(5);

            Node nn       = null;
            int  MemBlock = -1;

            bm.Search(1, new Point(597, 100), out nn, out MemBlock);

            int searchx = 0;

            searchx = Convert.ToInt32(Console.ReadLine());
            bm.Search(1, new Point(searchx, 100), out nn, out MemBlock);
            bm.Search(0, new Point(900, 100), out nn, out MemBlock);
        }
Beispiel #2
0
    public override void OnInspectorGUI()
    {
        DrawDefaultInspector();
        EditorGUI.BeginChangeCheck();

        NodeGenerator nodeGenerator = (NodeGenerator)target;

        if (GUILayout.Button("Find Neighbours"))
        {
            nodeGenerator.GetEdges();
        }

        if (GUILayout.Button("Delete All Connections"))
        {
            nodeGenerator.DeleteAllConnections();
        }

        if (EditorGUI.EndChangeCheck())
        {
            serializedObject.ApplyModifiedProperties();
            if (!Application.isPlaying)
            {
                EditorUtility.SetDirty(target);

                Node[] nodes = FindObjectsOfType <Node>();
                foreach (Node n in nodes)
                {
                    EditorUtility.SetDirty(n);
                }

                EditorApplication.MarkSceneDirty();
            }
        }
    }
Beispiel #3
0
        public IEnumerable <ObjectVariants> GetSubjects(ObjectVariants pred, ObjectVariants obj)
        {
            return(po_index.GetRecordsWithKeys(((OV_iriint)pred).code, obj)
                   .Cast <object[]>()

                   .Select(rec => NodeGenerator.GetUri(rec[0])));
        }
Beispiel #4
0
        public IEnumerable <TripleOVStruct> GetTriplesWithSubject(ObjectVariants subj)
        {
            return(ps_index.GetRecordsWithKey2(((OV_iriint)subj).code)
                   .Cast <object[]>()

                   .Select(rec => new TripleOVStruct(null, NodeGenerator.GetUri(rec[1]), rec[2].ToOVariant(NodeGenerator))));
        }
Beispiel #5
0
 void Awake()
 {
     nodeGenerator = new NodeGenerator(width, height);
     gridNodes     = nodeGenerator.GetNodes();
     spriteGrid    = new SpriteGrid(width, height, this.transform, gridNodes);
     spriteGrid.CreateBackground();
 }
Beispiel #6
0
        public void BuildIndexes()
        {
            //   _ng.coding_table.Save();
            //  _ng.coding_table.FreeMemory();

            System.Diagnostics.Stopwatch sw = new System.Diagnostics.Stopwatch();
            if (!table.TableCell.Root.Elements().Any())
            {
                Console.WriteLine("table empty!");
                return;
            }
            sw.Start();

            NodeGenerator.Build();

            sw.Stop();
            Console.WriteLine("Load data and nametable ok. Duration={0}", sw.ElapsedMilliseconds);
            sw.Restart();

            //ng.Build();
            ps_index.Build();

            sw.Stop();
            Console.WriteLine("ps_index.Build() ok. Duration={0}", sw.ElapsedMilliseconds);
            sw.Restart();

            po_index.Build();

            sw.Stop();
            Console.WriteLine("po_index Build index ok. Duration={0}", sw.ElapsedMilliseconds);
            sw.Restart();

            Start();
        }
Beispiel #7
0
 public IEnumerable <TripleOVStruct> GetTriplesWithPredicate(ObjectVariants pred)
 {
     return(ps_index.GetRecordsWithKey1(((OV_iriint)pred).code)
            .Cast <object[]>()
            .Select(rec =>
                    new TripleOVStruct(NodeGenerator.GetUri(rec[0]), null, rec[2].ToOVariant(NodeGenerator))));
 }
Beispiel #8
0
 public RdfNamedGraphs(NodeGenerator ng, Func <string, IGraph> graphCtor, Action <string> graphDrop)
 {
     getGraphUriByName = g => this.ng.GetUri(g.Name);
     this.ng           = ng;
     this.graphCtor    = graphCtor;
     this.graphDrop    = graphDrop;
 }
        public void VisitTarget_withTarget_generatesNode()
        {
            var target    = CreateTarget("sample");
            var generator = new NodeGenerator();

            generator.VisitTarget(target);
            Assert.That(generator.Nodes, Has.Count.EqualTo(1));
        }
Beispiel #10
0
	static public void Init(){
		GameObject obj=new GameObject();
		nodeGenerator=obj.AddComponent<NodeGenerator>();
		
		thisT=obj.transform;
		
		obj.name="NodeGenerator";
	}
Beispiel #11
0
 public IEnumerable <ObjectVariants> GetAllSubjects()
 {
     return
         (ps_index.GetRecordsAll()
          .Cast <object[]>()
          .Select(row => (int)row[0])
          .Distinct()
          .Select(uri => NodeGenerator.GetUri(uri)));
 }
Beispiel #12
0
        public override string GenerateControl(ControlInput input, ControlGenerationData data, int indent)
        {
            var destination = Unit.invoke.connection?.destination;

            if (!Unit.invoke.hasAnyConnection)
            {
                return("\n");
            }
            return(NodeGenerator.GetSingleDecorator(destination.unit as Unit, destination.unit as Unit).GenerateControl(destination, data, indent));
        }
        public void FromTurtle(long count, string fileName)
        {
            var generator = new TripleGeneratorBuffered(fileName, Name);

            generator.Start(list => triples.AddRange(
                                list.Select(
                                    t =>
                                    new TripleOV(
                                        NodeGenerator.AddIri(t.Subject),
                                        NodeGenerator.AddIri(t.Predicate),
                                        (ObjectVariants)t.Object))));
        }
Beispiel #14
0
    // Use this for initialization
    void Start()
    {
        info.SetActive(false);
        nodeEssences       = new Essence[Random.Range(1, 5)];
        nodeEssenceObjects = new GameObject[nodeEssences.Length];
        nodeGen            = GameObject.Find("SpawnManager").GetComponent <NodeGenerator>();

        for (int i = 0; i < nodeEssences.Length; i++)
        {
            nodeEssences[i] = nodeGen.availableEssences[Random.Range(0, nodeGen.availableEssences.Length)];

            /*if ( i > 0 && nodeEssences[i-1] == nodeEssences[i])
             * {
             *  i -= 1;
             *  return; // or break
             * }*/
            GameObject essPrefab = Instantiate(essencePrefab);
            essPrefab.transform.SetParent(info.transform);
            //added this cuz rotation was fckd in spawned structures
            //essPrefab.transform.rotation = Quaternion.Euler(info.transform.rotation.x, info.transform.rotation.y - 180, info.transform.rotation.z);
            //essPrefab.transform.position = info.transform.position;
            essPrefab.GetComponent <NodeDisplay>().nodeEssence = nodeEssences[i];

            nodeEssenceObjects[i] = essPrefab;

            switch (nodeEssences.Length)
            {
            case 1:
                padding = -0.1f;
                break;

            case 2:
                padding = 0.0f;
                break;

            case 3:
                padding = 0.1f;
                break;

            case 4:
                padding = 0.2f;
                break;

            default:
                padding = 0.0f;
                break;
            }
            //added rotation set
            //essPrefab.transform.rotation = Quaternion.Euler(info.transform.rotation.x, info.transform.rotation.y - 180, info.transform.rotation.z);
            //changed this to info
            essPrefab.transform.position = info.transform.position + new Vector3(((float)nodeEssences.Length / 10f + (padding /* start point */)) - (0.4f * i /* between aspects */), -0.5f, 0);
        }
    }
Beispiel #15
0
        internal void set_options_infromation(NodeGenerator.NodeGenerator node_gen, bool auto_save, string ver_storage, List<string> ac_list)
        {
            file_name.Text = node_gen.file_name;
            namespace_name.Text = node_gen.namespace_name;            
            visitor_interface_file_name.Text = node_gen.visitor_interface_file_name;
            tb_pcu_writer.Text = node_gen.pcu_writer_name;
            tb_pcu_reader.Text = node_gen.pcu_reader_name;

            autoSaveOnExit.Checked = auto_save;
            versionStorage.Text = ver_storage;
            AutoCompletionList.Lines = ac_list.ToArray();
        }
Beispiel #16
0
		public template_form(NodeGenerator.NodeGenerator ng)
		{
			//
			// Required for Windows Form Designer support
			//
			InitializeComponent();

			//
			// TODO: Add any constructor code after InitializeComponent call
			//
			node_gen=ng;
		}
 public NamedGraphsByFolders(DirectoryInfo directory, NodeGenerator ng, Func <DirectoryInfo, IGraph> graphCtor, Action <DirectoryInfo> graphDrop)
     : base(ng, s => graphCtor(new DirectoryInfo(directory + "/named graph " + CodeGraphName2DirName(s))), s => graphDrop(new DirectoryInfo(directory + "/named graph " + CodeGraphName2DirName(s))))
 {
     if (!directory.Exists)
     {
         directory.Create();
     }
     foreach (var graphDir in directory.EnumerateDirectories("named graph *", SearchOption.TopDirectoryOnly))
     {
         named.Add(DecodeDirName2GraphName(graphDir.Name.Substring(12)), graphCtor(graphDir));
     }
 }
Beispiel #18
0
 public IEnumerable <T> GetTriples <T>(Func <ObjectVariants, ObjectVariants, ObjectVariants, T> returns)
 {
     if (Table.TableCell.Root.Count() == 0)
     {
         return(Enumerable.Empty <T>());
     }
     return(ps_index.GetRecordsAll()
            .Cast <object[]>()
            .Select(
                rec =>
                returns(NodeGenerator.GetUri(rec[0]), NodeGenerator.GetUri(rec[1]),
                        rec[2].ToOVariant(NodeGenerator))));
 }
Beispiel #19
0
        public IEnumerable <TripleOVStruct> GetTriplesWithTextObject(ObjectVariants obj)
        {
            var tableRow = Table.Element(0);

            return(textObjectIndex.FindText(obj.ToString())
                   .Select(offset =>
            {
                tableRow.offset = offset;
                return tableRow.Get();
            })
                   .Cast <object[]>()
                   .Select(rec => new TripleOVStruct(NodeGenerator.GetUri(rec[0]), NodeGenerator.GetUri(rec[1]), null)));
        }
Beispiel #20
0
 void RegenerateNodes()
 {
     nodes.ResetNodes(false);
     for (var x = 0; x < 30;)
     {
         var point = new Vector2(Random.Range(-10f, 10f), Random.Range(-10f, 10f));
         if (NodeGenerator.CheckNodePosition(point, nodes.NodeList))
         {
             nodes.AddNode(point);
             x++;
         }
     }
 }
        public async Task TestTemplateHasNameAsync(string title)
        {
            var patternMatchingService = GetService <IPatternMatchingService>();
            var mwParserApi            = GetService <IMwParserApi>();
            var article = await GetArticleContainerAsync(title);

            var nodeGenerator = new NodeGenerator(mwParserApi.GetWikitextParser());

            var templates = nodeGenerator.GetTemplatesFromNode(await mwParserApi.GetArticleMwRootAsync(article.Content));

            var templateNames = templates.Select(x => x.GetTemplateName());

            Assert.IsTrue(templateNames.All(x => !string.IsNullOrWhiteSpace(x)));
        }
Beispiel #22
0
    void Start()
    {
        measure    = GetComponent <PathMeasurement>();
        nodes      = GetComponent <Nodes>();
        render     = GetComponent <RenderPaths>();
        generator  = GetComponent <NodeGenerator>();
        scoreText  = GameObject.FindWithTag("ScoreText").GetComponent <Text>();
        healthText = GameObject.FindWithTag("HealthText").GetComponent <Text>();
        undoButton = GameObject.FindWithTag("UndoButton").GetComponent <Button>();
        skipButton = GameObject.FindWithTag("SkipButton").GetComponent <Button>();
        minLine    = GameObject.FindWithTag("MinimumLine").GetComponent <RectTransform>();

        RestartGame();
    }
Beispiel #23
0
        internal void get_options_infromation(NodeGenerator.NodeGenerator node_gen, out bool auto_save, out string ver_storage, List<string> ac_list)
        {
            node_gen.file_name = file_name.Text;
            node_gen.namespace_name = namespace_name.Text;            
            node_gen.visitor_interface_file_name = visitor_interface_file_name.Text;
            node_gen.pcu_writer_file_name = tb_pcu_writer.Text + ".cs";
            node_gen.pcu_writer_name = tb_pcu_writer.Text;
            node_gen.pcu_reader_file_name = tb_pcu_reader.Text + ".cs";
            node_gen.pcu_reader_file_name_h = tb_pcu_reader.Text + ".h";
            node_gen.pcu_reader_file_name_cpp = tb_pcu_reader.Text + ".cpp";
            node_gen.pcu_reader_name = tb_pcu_reader.Text;

            auto_save = autoSaveOnExit.Checked;
            ver_storage = versionStorage.Text;
            ac_list.Clear();
            for (int i = 0; i < AutoCompletionList.Lines.Count(); i++)
                ac_list.Add(AutoCompletionList.Lines[i]);
        }
Beispiel #24
0
 public SparqlIri(SparqlExpression value, NodeGenerator q)
 {
     IsAggragate = value.IsAggragate;
     IsDistinct  = value.IsDistinct;
     Func        = result =>
     {
         var f = value.Func(result);
         if (f is IUriNode)
         {
             return(f);
         }
         if (f is ILiteralNode)      //TODO
         {
             return(q.CreateUriNode(f.Content));
         }
         throw new ArgumentException();
     };
 }
Beispiel #25
0
        private void ApplyAlternative(Alternative alternativeToApply)
        {
            var stackTop = Stack.Pop();

            if (!String.IsNullOrEmpty(alternativeToApply.Alias))
            {
                stackTop.Alias = alternativeToApply.Alias;
            }

            NestingLevel[stackTop] = LexingStream.GetPairsCount();

            for (var i = alternativeToApply.Count - 1; i >= 0; --i)
            {
                var newNode = NodeGenerator.Generate(alternativeToApply[i].Symbol, alternativeToApply[i].Options.Clone());

                stackTop.AddFirstChild(newNode);
                Stack.Push(newNode);
            }
        }
Beispiel #26
0
        //private const string rdf_syntax_ns = "http://www.w3.org/1999/02/22-rdf-syntax-ns#";
        //private const string xmlSchemaNs = "http://www.w3.org/2001/XMLSchema#";
        //private const string xmlSchemaPrefix="xsd:";

        //public static string[] GetAll()
        //{
        //    return new[]
        //    {
        //      // String,Bool,Decimal,Integer, Float, Double,
        //      // Date, Time, DateTime, DateTimeStamp,
        //      // GYear, GMonth, GDay, GYearMonth,           GMonthDay,      Duration   ,YearMonthDuration  , DayTimeDuration,
        //      // Byte, Short, Int, Long, UnsignedByte, unsignedShort, unsignedInt, unsignedLong,  positiveInteger,   nonNegativeInteger, negativeInteger, nonPositiveInteger,
        //      //hexBinary, base64Binary, anyURI, language, normalizedString, token, NMTOKEN,  Name, NCName
        //     Nil   ,RdfFirst,  RdfRest, RdfType
        //    };
        //}
        public SpecialTypesClass(NodeGenerator nodeGenerator)
        {
            //    date =nodeGenerator. CreateUriNode(Date);
            //    @string = nodeGenerator.CreateUriNode(String);
            //    //simpleLiteral = simple_literal_equals_string_literal
            //    //    ? String
            //    //    :  nodeGenerator.CreateUriNode(SpecialTypes.SimpleLiteral);
            //    langString = nodeGenerator.CreateUriNode(String);
            //    integer = nodeGenerator.CreateUriNode(Integer);
            //    @decimal = nodeGenerator.CreateUriNode(Decimal);
            //    @double = nodeGenerator.CreateUriNode(Double);
            //    @bool = nodeGenerator.CreateUriNode(Bool);
            //    @float = nodeGenerator.CreateUriNode(Float);
            //    timeDuration = nodeGenerator.CreateUriNode(DayTimeDuration);
            //    dateTime = nodeGenerator.CreateUriNode(DateTime);
            //nil = nodeGenerator.AddIri(Nil);
            //first = nodeGenerator.AddIri(RdfFirst);
            //rest = nodeGenerator.AddIri(RdfRest);
            type = nodeGenerator.AddIri(RdfType);
        }
 // Use this for initialization
 void Start()
 {
     nodes = FindObjectOfType <NodeGenerator>().GetComponent <NodeGenerator>();
 }
Beispiel #28
0
        public SparqlConcat(List <SparqlExpression> list, NodeGenerator q)
        {
            //SetExprType(ExpressionTypeEnum.stringOrWithLang);
            //foreach (var sb in list)
            //    sb.SetExprType(ExpressionTypeEnum.stringOrWithLang);

            if (list.Count == 0)
            {
                Const          = new OV_string(string.Empty);
                AggregateLevel = VariableDependenceGroupLevel.Const;
                //TypedOperator = r=>new OV_string(string.Empty);
            }
            else
            {
                if (list.All(expression => expression.Const != null))
                {
                    var values = list.Select(expression => expression.Const).ToArray();
                    if (values.All(o => o is OV_langstring))
                    {
                        var commonLang = ((OV_langstring)values[0]).Lang;
                        if (values.Cast <OV_langstring>().All(ls => ls.Lang.Equals(commonLang)))
                        {
                            Const          = new OV_langstring(string.Concat(values.Select(o => o.Content)), commonLang);
                            AggregateLevel = VariableDependenceGroupLevel.Const;
                        }
                    }
                    else if (values.All(o => o is OV_string))
                    {
                        Const = new OV_string(string.Concat(values.Select(v => v.Content).Cast <string>()));
                    }
                }
                else
                {
                    Operator = result =>
                    {
                        var values = list.Select(expression => expression.Const ?? expression.TypedOperator(result)).ToArray();
                        if (values.All(o => o is OV_langstring))
                        {
                            var commonLang = ((OV_langstring)values[0]).Lang;
                            if (values.Cast <OV_langstring>().All(ls => ls.Lang.Equals(commonLang)))
                            {
                                return(string.Concat(values.Select(o => o.Content)));
                            }
                        }
                        else if (values.All(o => o is OV_string))
                        {
                            return(string.Concat(values.Select(v => v.Content).Cast <string>()));
                        }
                        throw new ArgumentException();
                        //return q.CreateLiteralNode(string.Concat(values.Select(s => s.Content)));
                    };
                    AggregateLevel = SetAggregateLevel(list.Select(v => v.AggregateLevel).ToArray());
                    TypedOperator  = result =>
                    {
                        var values = list.Select(expression => expression.Const ?? expression.TypedOperator(result)).ToArray();
                        if (values.All(o => o is OV_langstring))
                        {
                            var commonLang = ((OV_langstring)values[0]).Lang;
                            if (values.Cast <OV_langstring>().All(ls => ls.Lang.Equals(commonLang)))
                            {
                                return(new OV_langstring(string.Concat(values.Select(o => o.Content)), commonLang));
                            }
                        }
                        else if (values.All(o => o is OV_string))
                        {
                            return(new OV_string(string.Concat(values.Select(v => v.Content).Cast <string>())));
                        }
                        throw new ArgumentException();
                        //return q.CreateLiteralNode(string.Concat(values.Select(s => s.Content)));
                    };
                }
            }
        }
Beispiel #29
0
		public static void generate(NodeGenerator.NodeGenerator ng)
		{
			template_form tf=new template_form(ng);
			tf.ShowDialog();
		}
Beispiel #30
0
 public NodeGeneratorTests()
 {
     _generator = new NodeGenerator();
     _graph     = _graphProvider.ProvideValid();
 }
Beispiel #31
0
        public ObjectVariants GetNode(Action <ObjectVariants, ObjectVariants, ObjectVariants> addTriple, NodeGenerator q)
        {
            ObjectVariants sparqlBlankNodeFirst = q.CreateBlankNode();
            ObjectVariants sparqlBlankNodeNext  = q.CreateBlankNode();

            foreach (var node in this.nodes.Take(this.nodes.Count - 1))
            {
                addTriple(sparqlBlankNodeNext, q.SpecialTypes.first, node);
                addTriple(sparqlBlankNodeNext, q.SpecialTypes.rest, sparqlBlankNodeNext = q.CreateBlankNode());
            }

            addTriple(sparqlBlankNodeNext, q.SpecialTypes.first, this.nodes[this.nodes.Count - 1]);
            addTriple(sparqlBlankNodeNext, q.SpecialTypes.rest, q.SpecialTypes.nil);
            return(sparqlBlankNodeFirst);
        }
        public SparqlEqualsExpression(SparqlExpression l, SparqlExpression r, NodeGenerator ng)
        {
            var lc = l.Const;
            var rc = r.Const;

            switch (NullablePairExt.Get(lc, rc))
            {
            case NP.bothNull:
                Operator       = result => l.TypedOperator(result).Equals(r.TypedOperator(result));
                AggregateLevel = SetAggregateLevel(l.AggregateLevel, r.AggregateLevel);
                break;

            case NP.leftNull:
                if (rc.Variant == ObjectVariantEnum.Iri)
                {
                    OV_iriint rcCoded = null;
                    Operator = result =>
                    {
                        var lVal = l.TypedOperator(result);
                        if (lVal.Variant == ObjectVariantEnum.Iri)
                        {
                            return(lVal.Equals(rc));
                        }
                        if (lVal.Variant == ObjectVariantEnum.IriInt)
                        {
                            if (rcCoded == null)
                            {
                                rcCoded = (OV_iriint)ng.GetUri((string)rc.Content);
                            }
                            return(((OV_iriint)lVal).code == rcCoded.code);
                        }
                        else
                        {
                            throw new AggregateException();
                        }
                    };
                }
                else
                {
                    Operator = result => l.TypedOperator(result).Equals(rc);
                }
                AggregateLevel = l.AggregateLevel;
                break;

            case NP.rigthNull:
                if (lc.Variant == ObjectVariantEnum.Iri)
                {
                    OV_iriint lcCoded = null;
                    Operator = result =>
                    {
                        var rVal = r.TypedOperator(result);
                        if (rVal.Variant == ObjectVariantEnum.Iri)
                        {
                            return(rVal.Equals(lc));
                        }
                        if (rVal.Variant == ObjectVariantEnum.IriInt)
                        {
                            if (lcCoded == null)
                            {
                                lcCoded = (OV_iriint)ng.GetUri((string)lc.Content);
                            }
                            return(((OV_iriint)rVal).code == lcCoded.code);
                        }
                        else
                        {
                            throw new AggregateException();
                        }
                    };
                }
                else
                {
                    Operator = result => lc.Equals(r.TypedOperator(result));
                }
                AggregateLevel = r.AggregateLevel;
                break;

            case NP.bothNotNull:
                Const = new OV_bool(lc.Equals(rc));
                break;
            }
            TypedOperator = result => new OV_bool(Operator(result));
        }
Beispiel #33
0
 private void Awake()
 {
     grid = GetComponent <NodeGenerator>();
 }
Beispiel #34
0
 public IEnumerable <TripleOVStruct> GetTriplesWithObject(ObjectVariants obj)
 {
     return(po_index.GetRecordsWithKey2(obj)
            .Cast <object[]>()
            .Select(rec => new TripleOVStruct(NodeGenerator.GetUri(rec[0]), NodeGenerator.GetUri(rec[1]), obj)));
 }
 public NodeGeneratorTests()
 {
     _generator = new NodeGenerator();
     _graph = _graphProvider.ProvideValid();
 }
Beispiel #36
0
	//~ static Transform refT;

	void Awake(){
		nodeGenerator=this;
		
		thisT=transform;
	}
Beispiel #37
0
        public SparqlStrDataType(SparqlExpression sparqlExpression1, SparqlExpression sparqlExpression2, NodeGenerator q)
        {
            // TODO: Complete member initialization
            switch (NullablePairExt.Get(sparqlExpression1.Const, sparqlExpression2.Const))
            {
            case NP.bothNull:
                TypedOperator  = result => q.CreateLiteralNode((string)sparqlExpression1.Operator(result), (string)sparqlExpression2.Operator(result));
                Operator       = res => sparqlExpression1.Operator(res);
                AggregateLevel = SetAggregateLevel(sparqlExpression1.AggregateLevel, sparqlExpression2.AggregateLevel);
                break;

            case NP.leftNull:
                TypedOperator  = result => q.CreateLiteralNode((string)sparqlExpression1.Operator(result), (string)sparqlExpression2.Const.Content);
                Operator       = res => sparqlExpression1.Operator(res);
                AggregateLevel = sparqlExpression1.AggregateLevel;
                break;

            case NP.rigthNull:
                TypedOperator  = result => q.CreateLiteralNode((string)sparqlExpression1.Const.Content, (string)sparqlExpression2.Operator(result));
                Operator       = res => sparqlExpression1.Const.Content;
                AggregateLevel = sparqlExpression2.AggregateLevel;

                break;

            case NP.bothNotNull:
                Const = q.CreateLiteralNode((string)sparqlExpression1.Const.Content, (string)sparqlExpression2.Const.Content);
                break;

            default:
                throw new ArgumentOutOfRangeException();
            }
        }
Beispiel #38
0
 // Use this for initialization
 void Start () {
     nodeGenerator = GameObject.Find("MapGenerator").GetComponent<NodeGenerator>();
     head = transform.Find("Head");
     audio = GetComponent<AudioSource>();
 }