/clients/cs/src/contentforshopping/elements/requireddestination.cs

http://google-gdata.googlecode.com/ · C# · 52 lines · 25 code · 3 blank · 24 comment · 0 complexity · 671ac162db9a0ef5713dad96b80dc09d MD5 · raw file

  1. /* Copyright (c) 2006 Google Inc.
  2. *
  3. * Licensed under the Apache License, Version 2.0 (the "License");
  4. * you may not use this file except in compliance with the License.
  5. * You may obtain a copy of the License at
  6. *
  7. * http://www.apache.org/licenses/LICENSE-2.0
  8. *
  9. * Unless required by applicable law or agreed to in writing, software
  10. * distributed under the License is distributed on an "AS IS" BASIS,
  11. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. * See the License for the specific language governing permissions and
  13. * limitations under the License.
  14. */
  15. using System;
  16. using Google.GData.Extensions;
  17. namespace Google.GData.ContentForShopping.Elements {
  18. public class RequiredDestination : SimpleElement {
  19. /// <summary>
  20. /// default constructor for sc:required_destination
  21. /// </summary>
  22. public RequiredDestination()
  23. : base(ContentForShoppingNameTable.RequiredDestination,
  24. ContentForShoppingNameTable.scDataPrefix,
  25. ContentForShoppingNameTable.BaseNamespace) {
  26. }
  27. /// <summary>
  28. /// Constructs a new RequiredDestination instance with the specified values.
  29. /// </summary>
  30. /// <param name="destination">The required destination.</param>
  31. public RequiredDestination(string destination)
  32. : base(ContentForShoppingNameTable.RequiredDestination,
  33. ContentForShoppingNameTable.scDataPrefix,
  34. ContentForShoppingNameTable.BaseNamespace) {
  35. this.Destination = destination;
  36. }
  37. /// <summary>
  38. /// Destination property accessor
  39. /// </summary>
  40. public string Destination {
  41. get {
  42. return Convert.ToString(Attributes[ContentForShoppingNameTable.Destination]);
  43. }
  44. set {
  45. Attributes[ContentForShoppingNameTable.Destination] = value;
  46. }
  47. }
  48. }
  49. }