Ejemplo n.º 1
0
        /// insert the taste captured by the taste sensor.
        public override void insert()
        {
            SparqlEndPoint instanceSparql = SparqlEndPoint.getInstance();       // gets the instance for the  singleton object

            // updates all information associated with a tast event
            instanceSparql.executeSparqlUpdate(sTaste);
        }
Ejemplo n.º 2
0
        /// returns a unique instance of SparqlEndPoint. If the instance is not created it must be instatiated now.
        // [MethodImpl(MethodImplOptions.Synchronized)]     // only remove the initial comment if you are having troubles with thread synchronization
        //                                                     Reason: it is very expensive resource

        public static SparqlEndPoint getInstance()
        {
            if (instance == null)
            {
                instance = new SparqlEndPoint();
            }

            return(instance);
        }
Ejemplo n.º 3
0
        /// insert the objects captured by the vision sensor.
        public override void insert()
        {
            SparqlEndPoint instanceSparql = SparqlEndPoint.getInstance();       // gets the instance for the  singleton object

            // updates all information associated with a vison event
            instanceSparql.executeSparqlUpdate(sPosition);
            instanceSparql.executeSparqlUpdate(sColor);
            instanceSparql.executeSparqlUpdate(sAnything);
            instanceSparql.executeSparqlUpdate(sVision);
        }
Ejemplo n.º 4
0
        /// insert the sound captured by the hear sensor.
        public override void insert()
        {
            SparqlEndPoint instanceSparql = SparqlEndPoint.getInstance();       // gets the instance for the  singleton object

            // updates all information associated with the event
            if (!String.IsNullOrEmpty(sPosition))
            {
                instanceSparql.executeSparqlUpdate(sPosition);                  // if a position was defined then updated it
                sPosition = null;                                               // just in case...
            }
            instanceSparql.executeSparqlUpdate(sHear);
        }