CodeVariableDeclarationStatement.cs 1017 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. //
  2. // System.CodeDom CodeVariableDeclarationStatement Class implementation
  3. //
  4. // Author:
  5. // Miguel de Icaza ([email protected])
  6. //
  7. // (C) 2001 Ximian, Inc.
  8. //
  9. namespace System.CodeDom {
  10. [Serializable]
  11. public class CodeVariableDeclarationStatement : CodeStatement {
  12. CodeExpression initExpression;
  13. string type, name;
  14. public CodeVariableDeclarationStatement () {}
  15. public CodeVariableDeclarationStatement (string type, string name)
  16. {
  17. this.type = type;
  18. this.name = name;
  19. }
  20. public CodeVariableDeclarationStatement (string type, string name,
  21. CodeExpression initExpression)
  22. {
  23. this.type = type;
  24. this.name = name;
  25. this.initExpression = initExpression;
  26. }
  27. public CodeExpression InitExpression {
  28. get {
  29. return initExpression;
  30. }
  31. set {
  32. initExpression = value;
  33. }
  34. }
  35. public string Name {
  36. get {
  37. return name;
  38. }
  39. set {
  40. name = value;
  41. }
  42. }
  43. public string Type {
  44. get {
  45. return type;
  46. }
  47. set {
  48. type = value;
  49. }
  50. }
  51. }
  52. }