IsOwner() public method

public IsOwner ( User asker ) : bool
asker User
return bool
コード例 #1
0
ファイル: User.cs プロジェクト: bagheera/askme
 public virtual void AcceptAnswer(Question question,Answer answer)
 {
     if (!question.IsOwner(this))
         throw new NotSupportedException("An answer can be accepted only by the question's owner");
     question.AcceptSolution(answer);
 }