Hi again, Since the error codes have to be written for the JSONiq implementation, shall I start doing so by adding new enum values for ErrorCode starting with JQTY and adding the description to the XMLQueryErrorMessages.properties?
Thank you. Yours sincerely, Riyafa On Jun 6, 2016 4:44 PM, "Riyafa Abdul Hameed" <[email protected]> wrote: > Hi, > > Thanks Till. I have implemented the runtime for objects[1], but I am not > sure of the implementation though it is working and the Object is printed > in the console from the XMLSerializer class. I think this implementation > needs improvements and testing. I would like to know how/where to write > test classes for the implementation. Also please let me know if the > implementation is correct. > > [1] https://github.com/apache/vxquery/pull/51 > > Thank you. > > Yours sincerely, > Riyafa > > On 3 June 2016 at 03:43, Till Westmann <[email protected]> wrote: > >> Hi Riyafa, >> >> I think that the sample that I pointed you to might not have been the best >> one as it depends on methods that are available in superclasses that do >> common work for the node constructors. >> >> The top level contract for the evaluators is IScalarEvaluator and that >> only >> has one method >> >> void evaluate(IFrameTupleReference tuple, IPointable result) >> >> which takes in a IFrameTupleReference (that provides a value for each >> variable in the tuple) and an IPointable that should point to the (scalar) >> result after evaluation. >> >> The abstract class AbstractTaggedValueArgumentScalarEvaluator factors out >> some common code for the common pattern that most of our evaluators >> follow: >> 1) pass n IScalarEvaluator to the constructor >> 2) evaluate each of those (argument) scalar evaluators on each >> IFrameTupleReference that is passed to an evaluate call to get n result >> values for each tuple >> 3) pass those n values (stored in a TaggedValuePointable array) on to a >> simpler evaluate-method that is declared in >> AbstractTaggedValueArgumentScalarEvaluator and implemented in the >> subclasses. >> >> The AbstractNodeConstructorScalarEvaluator then refines this even more for >> nodes, but I think that that's not helpful for our object (or array) >> constructors as we e.g. don't consider using dictionaries for those for >> now. >> >> Does this help/make sense? >> >> Cheers, >> Till >> >> On 2 Jun 2016, at 7:22, Riyafa Abdul Hameed wrote: >> >> > Hi again, >> > >> > Sorry about my ignorance. On attempting to implement the >> > ObjectNodeConstructorScalarEvaluator I have started wondering about the >> > arguments passed to the method constructNode--I am not sure how I could >> > find out what would be passed as arguments for the method in >> > ObjectNodeConstructorScalarEvaluator. Can I assume key and value pair >> would >> > be passed as the TaggedValuePointable[] argument? Or where is this >> method >> > used and how can I find out about the arguments? I have also tried >> > debugging to no avail. Again sorry about the ignorance. I read the >> paper[1] >> > and still couldn't get a grasp of what's happening (I will read again to >> > see if I could figure it out) >> > >> > [1] http://dl.acm.org/citation.cfm?id=2806941 >> > >> > Thank you. >> > >> > Yours sincerely, >> > Riyafa >> > >> > On 2 June 2016 at 10:43, Riyafa Abdul Hameed <[email protected]> >> > wrote: >> > >> >> Hi, >> >> >> >> When attempting to implement runtime operators for Object >> implementation, >> >> I have come across the following issues: >> >> >> >> - Should there be a ConstructorScalarEvaluator for PairConstructor? >> >> - Should I be checking if the keys are unique in the >> >> ObjectNodeConstructorScalarEvaluator? >> >> >> >> >> >> Thank you. >> >> >> >> Yours sincerely, >> >> >> >> Riyafa >> >> >> >> >> >> >> >> -- >> >> Riyafa Abdul Hameed >> >> Undergraduate, University of Moratuwa >> >> >> >> Email: [email protected] >> >> Website: https://riyafa.wordpress.com/ <http://riyafa.wordpress.com/> >> >> <http://facebook.com/riyafa.ahf> <http://lk.linkedin.com/in/riyafa> >> >> <http://twitter.com/Riyafa1> >> >> >> > >> > >> > >> > -- >> > Riyafa Abdul Hameed >> > Undergraduate, University of Moratuwa >> > >> > Email: [email protected] >> > Website: https://riyafa.wordpress.com/ <http://riyafa.wordpress.com/> >> > <http://facebook.com/riyafa.ahf> <http://lk.linkedin.com/in/riyafa> >> > <http://twitter.com/Riyafa1> >> > > > > -- > Riyafa Abdul Hameed > Undergraduate, University of Moratuwa > > Email: [email protected] > Website: https://riyafa.wordpress.com/ <http://riyafa.wordpress.com/> > <http://facebook.com/riyafa.ahf> <http://lk.linkedin.com/in/riyafa> > <http://twitter.com/Riyafa1> >
