PageRenderTime 56ms CodeModel.GetById 19ms RepoModel.GetById 1ms app.codeStats 0ms

/TimeSheetReporting/TimeSheetReporting.Web/Service/TimeSheetService.metadata.cs

#
C# | 118 lines | 58 code | 24 blank | 36 comment | 0 complexity | 149c5e2cb6e62a12a7ac4b7333ec88a6 MD5 | raw file
  1. #pragma warning disable 649 // disable compiler warnings about unassigned fields
  2. namespace TimeSheetReporting.Web.Model
  3. {
  4. using System;
  5. using System.Collections.Generic;
  6. using System.ComponentModel;
  7. using System.ComponentModel.DataAnnotations;
  8. using System.Data.Objects.DataClasses;
  9. using System.Linq;
  10. using System.Web.DomainServices;
  11. using System.Web.Ria;
  12. using System.Web.Ria.Services;
  13. // The MetadataTypeAttribute identifies EffortMetadata as the class
  14. // that carries additional metadata for the Effort class.
  15. [MetadataTypeAttribute(typeof(Effort.EffortMetadata))]
  16. public partial class Effort
  17. {
  18. // This class allows you to attach custom attributes to properties
  19. // of the Effort class.
  20. //
  21. // For example, the following marks the Xyz property as a
  22. // required field and specifies the format for valid values:
  23. // [Required]
  24. // [RegularExpression("[A-Z][A-Za-z0-9]*")]
  25. // [StringLength(32)]
  26. // public string Xyz;
  27. internal sealed class EffortMetadata
  28. {
  29. // Metadata classes are not meant to be instantiated.
  30. private EffortMetadata()
  31. {
  32. }
  33. public DateTime Date;
  34. public string Description;
  35. public double Hours;
  36. public int Id;
  37. [Include]
  38. public Member Member;
  39. [Include]
  40. public Project Project;
  41. }
  42. }
  43. // The MetadataTypeAttribute identifies MemberMetadata as the class
  44. // that carries additional metadata for the Member class.
  45. [MetadataTypeAttribute(typeof(Member.MemberMetadata))]
  46. public partial class Member
  47. {
  48. // This class allows you to attach custom attributes to properties
  49. // of the Member class.
  50. //
  51. // For example, the following marks the Xyz property as a
  52. // required field and specifies the format for valid values:
  53. // [Required]
  54. // [RegularExpression("[A-Z][A-Za-z0-9]*")]
  55. // [StringLength(32)]
  56. // public string Xyz;
  57. internal sealed class MemberMetadata
  58. {
  59. // Metadata classes are not meant to be instantiated.
  60. private MemberMetadata()
  61. {
  62. }
  63. public EntityCollection<Effort> Effort;
  64. public int Id;
  65. public string Name;
  66. }
  67. }
  68. // The MetadataTypeAttribute identifies ProjectMetadata as the class
  69. // that carries additional metadata for the Project class.
  70. [MetadataTypeAttribute(typeof(Project.ProjectMetadata))]
  71. public partial class Project
  72. {
  73. // This class allows you to attach custom attributes to properties
  74. // of the Project class.
  75. //
  76. // For example, the following marks the Xyz property as a
  77. // required field and specifies the format for valid values:
  78. // [Required]
  79. // [RegularExpression("[A-Z][A-Za-z0-9]*")]
  80. // [StringLength(32)]
  81. // public string Xyz;
  82. internal sealed class ProjectMetadata
  83. {
  84. // Metadata classes are not meant to be instantiated.
  85. private ProjectMetadata()
  86. {
  87. }
  88. public EntityCollection<Effort> Effort;
  89. public int Id;
  90. public string Name;
  91. }
  92. }
  93. }
  94. #pragma warning restore 649 // re-enable compiler warnings about unassigned fields