Пример #1
0
        public static OpportunityWrapper Load(Opportunity Opportunity)
        {
            if (Opportunity == null)
            {
                throw new ArgumentException("Opportunity cannot be null");
            }

            return(new OpportunityWrapper(Opportunity));
        }
Пример #2
0
        public static Task Create(string description, Opportunity opp)
        {
            if (string.IsNullOrEmpty(description))
            {
                throw new ArgumentException("Description cannot be null or empty");
            }

            return(new Task(description, opp));
        }
Пример #3
0
        public void SetOpportunity(Opportunity o)
        {
            if (this.Kase != null || this.Party != null)
            {
                throw new ArgumentException("Only one of kase, opportunity and party can be populated");
            }

            this.Opportunity = o;
        }
Пример #4
0
 private OpportunityWrapper(Opportunity Opportunity)
 {
     this.Opportunity   = Opportunity;
     this.Opportunities = null;
 }
Пример #5
0
 private Task(string description, Opportunity opp)
 {
     this.Description = description;
     this.Opportunity = opp;
 }