protected CsdlSemanticsVocabularyAnnotation(CsdlSemanticsSchema schema, IEdmVocabularyAnnotatable targetContext, CsdlSemanticsAnnotations annotationsContext, CsdlAnnotation annotation, string qualifier)
     : base(annotation)
 {
     this.schema = schema;
     this.Annotation = annotation;
     this.qualifier = qualifier ?? annotation.Qualifier;
     this.targetContext = targetContext;
     this.annotationsContext = annotationsContext;
 }
Example #2
0
 public void AddAnnotation(CsdlAnnotation annotation)
 {
     this.AddUntypedAnnotation(annotation);
 }
Example #3
0
 private IEdmVocabularyAnnotation WrapVocabularyAnnotation(CsdlAnnotation annotation, CsdlSemanticsSchema schema, IEdmVocabularyAnnotatable targetContext, CsdlSemanticsAnnotations annotationsContext, string qualifier)
 {
     return EdmUtil.DictionaryGetOrUpdate(
         this.wrappedAnnotations,
         annotation,
         ann => new CsdlSemanticsValueAnnotation(schema, targetContext, annotationsContext, ann, qualifier));
 }
        private IEdmVocabularyAnnotation WrapVocabularyAnnotation(CsdlAnnotation annotation, CsdlSemanticsSchema schema, IEdmVocabularyAnnotatable targetContext, CsdlSemanticsAnnotations annotationsContext, string qualifier)
        {
            CsdlSemanticsVocabularyAnnotation result;

            // Guarantee that multiple calls to wrap a given annotation all return the same object.
            if (this.wrappedAnnotations.TryGetValue(annotation, out result))
            {
                return result;
            }

            result = (CsdlSemanticsVocabularyAnnotation)new CsdlSemanticsValueAnnotation(schema, targetContext, annotationsContext, annotation, qualifier);

            this.wrappedAnnotations[annotation] = result;
            return result;
        }
 public CsdlSemanticsValueAnnotation(CsdlSemanticsSchema schema, IEdmVocabularyAnnotatable targetContext, CsdlSemanticsAnnotations annotationsContext, CsdlAnnotation annotation, string externalQualifier)
     : base(schema, targetContext, annotationsContext, annotation, externalQualifier)
 {
 }