contract/lib/BeanUser.js
/**
     * Checks the equality between the parameter and this instance object.
     * @param {BeanUser} bean Object to be verified about equality.
     */
Checks the equality between the parameter and this instance object.
@param {BeanUser} bean Object to be verified about equality.
Checks the equality between the parameter and this instance object . @param { BeanUser } bean Object to be verified about equality .
equals(bean){
        if (bean == null || bean == undefined){
            return false;
        } else if (this.type != bean.type){
            return false;
        } else if (this.version != bean.version){
            return false;
        } else if (this.publicId != bean.publicId){
            return false;
        } 
        let instanceUser = UserId.createUserId(this.userId);
        let beanUser = UserId.createUserId(bean.userId);
        if (!instanceUser.equals(beanUser)) {
            return false;
        }
        logWrite(`[equals] UserId equals TRUE`);
        return true;
    }
equals ( bean ) { if ( bean == null || bean == undefined ) { return false ; } else if ( this . type != bean . type ) { return false ; } else if ( this . version != bean . version ) { return false ; } else if ( this . publicId != bean . publicId ) { return false ; } let instanceUser = UserId . createUserId ( this . userId ) ; let beanUser = UserId . createUserId ( bean . userId ) ; if ( ! instanceUser . equals ( beanUser ) ) { return false ; } logWrite ( ` ` ) ; return true ; }
Checks the equality between the parameter and this instance object.
Checks the equality between the parameter and this instance object .