Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: V4.0_WD01
    • Fix Version/s: V4.0_WD01
    • Component/s: CSDL XML
    • Labels:
      None
    • Environment:

      [Proposed]

    • Proposal:
      Hide

      Define the following symbolic names:
      odata.mediaEditLink
      odata.mediaReadLink
      odata.mediaContentType

      Allow to use these symbolic names in the path attribute of the annotation element.

      They may also be appended to Named Stream properties, separated by an @ sign: NamedStream@odata.mediaEditLink etc.

      Example:

      <EntityType Name="SomeMediaLinkEntryType" HasStream= "true">
      <Annotation Term="Movie.MovieURL" Path="@odata.mediaReadLink"/>
      <Annotation Term="Movie.MovieMimeType" Path="@odata.mediaContentType"/>
      <Property Name="Something" Type="String">
      <Property Name="SomethingElse" Type="String"/>
      </EntityType>

      Accepted: https://www.oasis-open.org/committees/download.php/48174/odata-meeting-24_on-20130207-minutes.html#odata-227

      Show
      Define the following symbolic names: odata.mediaEditLink odata.mediaReadLink odata.mediaContentType Allow to use these symbolic names in the path attribute of the annotation element. They may also be appended to Named Stream properties, separated by an @ sign: NamedStream@odata.mediaEditLink etc. Example: <EntityType Name="SomeMediaLinkEntryType" HasStream= "true"> <Annotation Term="Movie.MovieURL" Path="@odata.mediaReadLink"/> <Annotation Term="Movie.MovieMimeType" Path="@odata.mediaContentType"/> <Property Name="Something" Type="String"> <Property Name="SomethingElse" Type="String"/> </EntityType> Accepted: https://www.oasis-open.org/committees/download.php/48174/odata-meeting-24_on-20130207-minutes.html#odata-227
    • Resolution:
      Show
      https://www.oasis-open.org/committees/download.php/48200/odata-core-v1.0-wd01-part3-csdl-2013-02-11-RH.doc Accepted: https://www.oasis-open.org/committees/download.php/48269/odata-meeting-25_on-20130214-minutes.html#odata-227

      Description

      An Annotation should be able to use one of a set of pre-defined symbolic names when specifying a value.
      For example, the value of the "MovieURL" Annotation should be the MediaRessource of the "Movie" type (which is a Media Link Entry).

        Attachments

          Activity

          Hide
          ralfhandl Ralf Handl added a comment - - edited

          Using the @ sign as the separator for named stream properties (only) feels odd, because until now we don't differentiate "term casts" in CSDL Path expressions by property type. Accessing a display.hidden annotation on a property would be

          Path="PropertyName/display.hidden"

          independently of whether the property is primitive or complex or navigation. So

          Path="NamedStream/odata.mediaReadLink"

          is more consistent than

          Path="NamedStream@odata.mediaReadLink"

          We COULD consistently switch to the @ sign for all "term casts":

          Path="PropertyName@display.hidden"

          The examples in ODATA-108 and ODATA-109 would then be changed to

          <PropertyValue Property="PhoneNumbers" Path="Phones@vCard.PhoneNumber#work" />

          and

          <Annotation Term="Display.Caption" Path="@CreativeWorks.Movie/Title"/> (empty prefix means "this", then look for annotation)
          <Annotation Term="Display.Caption" Path="@vCard.Contact/Fullname" />

          <Property Name="Something" Type="String">
          <Annotation Term="Display.Hidden" Path="Something@Core.ReadOnly" />
          </Property>
          <Property Name="SomethingElse" Type="String">
          <Annotation Term="Display.Hidden" Path="Something@Core.ReadOnly" />
          </Property>

          Thoughts?

          Show
          ralfhandl Ralf Handl added a comment - - edited Using the @ sign as the separator for named stream properties (only) feels odd, because until now we don't differentiate "term casts" in CSDL Path expressions by property type. Accessing a display.hidden annotation on a property would be Path="PropertyName/display.hidden" independently of whether the property is primitive or complex or navigation. So Path="NamedStream/odata.mediaReadLink" is more consistent than Path="NamedStream@odata.mediaReadLink" We COULD consistently switch to the @ sign for all "term casts": Path="PropertyName@display.hidden" The examples in ODATA-108 and ODATA-109 would then be changed to <PropertyValue Property="PhoneNumbers" Path="Phones@vCard.PhoneNumber#work" /> and <Annotation Term="Display.Caption" Path="@CreativeWorks.Movie/Title"/> (empty prefix means "this", then look for annotation) <Annotation Term="Display.Caption" Path="@vCard.Contact/Fullname" /> <Property Name="Something" Type="String"> <Annotation Term="Display.Hidden" Path="Something@Core.ReadOnly" /> </Property> <Property Name="SomethingElse" Type="String"> <Annotation Term="Display.Hidden" Path="Something@Core.ReadOnly" /> </Property> Thoughts?

            People

            • Assignee:
              handl Ralf Handl
              Reporter:
              martinzurmuehl Martin Zurmuehl
            • Watchers:
              0 Start watching this issue

              Dates

              • Due:
                Created:
                Updated:
                Resolved: