CodeCatchClause.cs 868 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. //
  2. // System.CodeDom CodeCatchClaus 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 CodeCatchClause {
  12. CodeParameterDeclarationExpression condition;
  13. CodeStatementCollection statements;
  14. public CodeCatchClause ()
  15. {
  16. this.statements = new CodeStatementCollection ();
  17. }
  18. public CodeCatchClause (CodeParameterDeclarationExpression condition,
  19. CodeStatement [] statements)
  20. {
  21. this.condition = condition;
  22. this.statements = new CodeStatementCollection ();
  23. this.statements.AddRange (statements);
  24. }
  25. public CodeStatementCollection Statements {
  26. get {
  27. return statements;
  28. }
  29. }
  30. public CodeParameterDeclarationExpression Condition {
  31. get {
  32. return condition;
  33. }
  34. set {
  35. condition = value;
  36. }
  37. }
  38. }
  39. }