this.passcode = passcode;
}
@Override
protected EventEx doExecute(PartakeConnection con, IPartakeDAOs daos) throws DAOException, PartakeException {
EventEx event = EventDAOFacade.getEventEx(con, daos, eventId);
if (event == null)
throw new PartakeException(UserErrorCode.INVALID_EVENT_ID);
if (!StringUtils.isBlank(event.getPasscode())) {
// owner および manager は見ることが出来る。
if (user != null && PrivateEventShowPermission.check(event, user)) {
// OK. You have the right to show this event.
} else if (StringUtils.equals(event.getPasscode(), passcode)) {
// OK. The same passcode.
} else {
// public でなければ、passcode を入れなければ見ることが出来ない
throw new PartakeException(UserErrorCode.FORBIDDEN_EVENT_SHOW);
}