public void setResult(RefUpdate.Result r) {switch (r) {case NOT_ATTEMPTED:setResult(Result.NOT_ATTEMPTED);break;case LOCK_FAILURE:case IO_FAILURE:setResult(Result.LOCK_FAILURE);break;case NO_CHANGE:case NEW:case FORCED:case FAST_FORWARD:setResult(Result.OK);break;case REJECTED:setResult(Result.REJECTED_NONFASTFORWARD);break;case REJECTED_CURRENT_BRANCH:setResult(Result.REJECTED_CURRENT_BRANCH);break;case REJECTED_MISSING_OBJECT:setResult(Result.REJECTED_MISSING_OBJECT);break;case REJECTED_OTHER_REASON:setResult(Result.REJECTED_OTHER_REASON);break;default:setResult(Result.REJECTED_OTHER_REASON, r.name());break;}}

public virtual void SetResult(RefUpdate.Result r){switch (r){case RefUpdate.Result.NOT_ATTEMPTED:{SetResult(ReceiveCommand.Result.NOT_ATTEMPTED);break;}case RefUpdate.Result.LOCK_FAILURE:case RefUpdate.Result.IO_FAILURE:{SetResult(ReceiveCommand.Result.LOCK_FAILURE);break;}case RefUpdate.Result.NO_CHANGE:case RefUpdate.Result.NEW:case RefUpdate.Result.FORCED:case RefUpdate.Result.FAST_FORWARD:{SetResult(ReceiveCommand.Result.OK);break;}case RefUpdate.Result.REJECTED:{SetResult(ReceiveCommand.Result.REJECTED_NONFASTFORWARD);break;}case RefUpdate.Result.REJECTED_CURRENT_BRANCH:{SetResult(ReceiveCommand.Result.REJECTED_CURRENT_BRANCH);break;}default:{SetResult(ReceiveCommand.Result.REJECTED_OTHER_REASON, r.ToString());break;break;}}}
