java.lang.Byte.equals()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(16.7k)|赞(0)|评价(0)|浏览(135)

本文整理了Java中java.lang.Byte.equals()方法的一些代码示例,展示了Byte.equals()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Byte.equals()方法的具体详情如下:
包路径:java.lang.Byte
类名称:Byte
方法名:equals

Byte.equals介绍

[英]Compares this object with the specified object and indicates if they are equal. In order to be equal, object must be an instance of Byte and have the same byte value as this object.
[中]

代码示例

代码示例来源:origin: apache/hbase

@Override
public boolean equals(Object obj) {
 if (!(obj instanceof DeleteVersionVisibilityExpressionFilter)) {
  return false;
 }
 if (this == obj){
  return true;
 }
 DeleteVersionVisibilityExpressionFilter f = (DeleteVersionVisibilityExpressionFilter)obj;
 return this.deleteCellVisTags.equals(f.deleteCellVisTags) &&
   this.deleteCellVisTagsFormat.equals(f.deleteCellVisTagsFormat);
}

代码示例来源:origin: hs-web/hsweb-framework

@GetMapping("/all")
@ApiOperation("获取用户可选择的仪表盘配置")
public ResponseMessage<List<UserDashBoardResponse>> getUserAllDashBoardConfig(Authentication authentication) {
  List<UserDashBoardResponse> configList = dashBoardService.select()
      .stream()
      .filter(Objects::nonNull)
      .filter(config-> DataStatus.STATUS_ENABLED.equals(config.getStatus()))
      //过滤权限
      .filter(config -> StringUtils.isEmpty(config) ||
          AuthenticationPredicate.has(config.getPermission()).test(authentication))
      .map(config -> config.copyTo(new UserDashBoardResponse()))
      .collect(Collectors.toList());
  return ResponseMessage.ok(configList);
}

代码示例来源:origin: hs-web/hsweb-framework

protected OAuth2Client checkClient(OAuth2Client client) {
  if (client == null) {
    throw new GrantTokenException(CLIENT_NOT_EXIST);
  }
  if (!DataStatus.STATUS_ENABLED.equals(client.getStatus())) {
    throw new GrantTokenException(CLIENT_DISABLED);
  }
  return client;
}

代码示例来源:origin: hs-web/hsweb-framework

@Override
public DynamicFormDeployLogEntity selectLastDeployed(String formId) {
  Objects.requireNonNull(formId);
  DynamicFormDeployLogEntity deployed = createQuery()
      .where(DynamicFormDeployLogEntity.formId, formId)
      .orderByDesc(DynamicFormDeployLogEntity.deployTime)
      .single();
  if (null != deployed && DataStatus.STATUS_ENABLED.equals(deployed.getStatus())) {
    return deployed;
  }
  return null;
}

代码示例来源:origin: hs-web/hsweb-framework

@Override
@Cacheable(key = "'dictDefineById:'+#id")
public DictDefine getDefine(String id) {
  DictionaryEntity entity = dictionaryService.selectByPk(id);
  if (entity == null) {
    return super.getDefine(id);
  }
  List<EnumDict<Object>> items = (List) itemService.selectByDictId(id)
      .stream()
      .filter(e -> DataStatus.STATUS_ENABLED.equals(e.getStatus()))
      .collect(Collectors.toList());
  return DefaultDictDefine.builder()
      .id(id)
      .comments(entity.getDescribe())
      .items(items)
      .build();
}

代码示例来源:origin: hs-web/hsweb-framework

@Override
public DynamicFormDeployLogEntity selectDeployed(String formId, long version) {
  Objects.requireNonNull(formId);
  DynamicFormDeployLogEntity deployed = createQuery()
      .where(DynamicFormDeployLogEntity.formId, formId)
      .and(DynamicFormDeployLogEntity.version, version)
      .orderByDesc(DynamicFormDeployLogEntity.deployTime)
      .single();
  if (null != deployed && DataStatus.STATUS_ENABLED.equals(deployed.getStatus())) {
    return deployed;
  }
  return null;
}

代码示例来源:origin: hs-web/hsweb-framework

@Override
public OAuth2SessionBuilder create(String serverId) {
  OAuth2ServerConfig configEntity = oAuth2ServerConfigService.findById(serverId);
  if (null == configEntity || !DataStatus.STATUS_ENABLED.equals(configEntity.getStatus())) {
    throw new NotFoundException("server not found!");
  }
  return new SimpleOAuth2SessionBuilder(oAuth2UserTokenService, configEntity, oAuth2RequestBuilderFactory,
      lockManager.getReadWriteLock("oauth2-server-lock." + serverId));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  UpmsUserPermission other = (UpmsUserPermission) that;
  return (this.getUserPermissionId() == null ? other.getUserPermissionId() == null : this.getUserPermissionId().equals(other.getUserPermissionId()))
    && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
    && (this.getPermissionId() == null ? other.getPermissionId() == null : this.getPermissionId().equals(other.getPermissionId()))
    && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  UcenterUserOauth other = (UcenterUserOauth) that;
  return (this.getUserOauthId() == null ? other.getUserOauthId() == null : this.getUserOauthId().equals(other.getUserOauthId()))
    && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
    && (this.getOauthId() == null ? other.getOauthId() == null : this.getOauthId().equals(other.getOauthId()))
    && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
    && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
    && (Arrays.equals(this.getOpenId(), other.getOpenId()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  PayOutOrder other = (PayOutOrder) that;
  return (this.getPayOutOrderId() == null ? other.getPayOutOrderId() == null : this.getPayOutOrderId().equals(other.getPayOutOrderId()))
    && (this.getPayMchId() == null ? other.getPayMchId() == null : this.getPayMchId().equals(other.getPayMchId()))
    && (this.getPayVendorId() == null ? other.getPayVendorId() == null : this.getPayVendorId().equals(other.getPayVendorId()))
    && (this.getAmount() == null ? other.getAmount() == null : this.getAmount().equals(other.getAmount()))
    && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  PayInOrder other = (PayInOrder) that;
  return (this.getPayInOrderId() == null ? other.getPayInOrderId() == null : this.getPayInOrderId().equals(other.getPayInOrderId()))
    && (this.getPayVendorId() == null ? other.getPayVendorId() == null : this.getPayVendorId().equals(other.getPayVendorId()))
    && (this.getPayMchId() == null ? other.getPayMchId() == null : this.getPayMchId().equals(other.getPayMchId()))
    && (this.getAmount() == null ? other.getAmount() == null : this.getAmount().equals(other.getAmount()))
    && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  CmsCategory other = (CmsCategory) that;
  return (this.getCategoryId() == null ? other.getCategoryId() == null : this.getCategoryId().equals(other.getCategoryId()))
    && (this.getPid() == null ? other.getPid() == null : this.getPid().equals(other.getPid()))
    && (this.getLevel() == null ? other.getLevel() == null : this.getLevel().equals(other.getLevel()))
    && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
    && (this.getDescription() == null ? other.getDescription() == null : this.getDescription().equals(other.getDescription()))
    && (this.getIcon() == null ? other.getIcon() == null : this.getIcon().equals(other.getIcon()))
    && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
    && (this.getAlias() == null ? other.getAlias() == null : this.getAlias().equals(other.getAlias()))
    && (this.getSystemId() == null ? other.getSystemId() == null : this.getSystemId().equals(other.getSystemId()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()))
    && (this.getOrders() == null ? other.getOrders() == null : this.getOrders().equals(other.getOrders()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  UpmsPermission other = (UpmsPermission) that;
  return (this.getPermissionId() == null ? other.getPermissionId() == null : this.getPermissionId().equals(other.getPermissionId()))
    && (this.getSystemId() == null ? other.getSystemId() == null : this.getSystemId().equals(other.getSystemId()))
    && (this.getPid() == null ? other.getPid() == null : this.getPid().equals(other.getPid()))
    && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
    && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
    && (this.getPermissionValue() == null ? other.getPermissionValue() == null : this.getPermissionValue().equals(other.getPermissionValue()))
    && (this.getUri() == null ? other.getUri() == null : this.getUri().equals(other.getUri()))
    && (this.getIcon() == null ? other.getIcon() == null : this.getIcon().equals(other.getIcon()))
    && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()))
    && (this.getOrders() == null ? other.getOrders() == null : this.getOrders().equals(other.getOrders()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  CmsTag other = (CmsTag) that;
  return (this.getTagId() == null ? other.getTagId() == null : this.getTagId().equals(other.getTagId()))
    && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
    && (this.getDescription() == null ? other.getDescription() == null : this.getDescription().equals(other.getDescription()))
    && (this.getIcon() == null ? other.getIcon() == null : this.getIcon().equals(other.getIcon()))
    && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
    && (this.getAlias() == null ? other.getAlias() == null : this.getAlias().equals(other.getAlias()))
    && (this.getSystemId() == null ? other.getSystemId() == null : this.getSystemId().equals(other.getSystemId()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()))
    && (this.getOrders() == null ? other.getOrders() == null : this.getOrders().equals(other.getOrders()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  UpmsUser other = (UpmsUser) that;
  return (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
    && (this.getUsername() == null ? other.getUsername() == null : this.getUsername().equals(other.getUsername()))
    && (this.getPassword() == null ? other.getPassword() == null : this.getPassword().equals(other.getPassword()))
    && (this.getSalt() == null ? other.getSalt() == null : this.getSalt().equals(other.getSalt()))
    && (this.getRealname() == null ? other.getRealname() == null : this.getRealname().equals(other.getRealname()))
    && (this.getAvatar() == null ? other.getAvatar() == null : this.getAvatar().equals(other.getAvatar()))
    && (this.getPhone() == null ? other.getPhone() == null : this.getPhone().equals(other.getPhone()))
    && (this.getEmail() == null ? other.getEmail() == null : this.getEmail().equals(other.getEmail()))
    && (this.getSex() == null ? other.getSex() == null : this.getSex().equals(other.getSex()))
    && (this.getLocked() == null ? other.getLocked() == null : this.getLocked().equals(other.getLocked()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  CmsComment other = (CmsComment) that;
  return (this.getCommentId() == null ? other.getCommentId() == null : this.getCommentId().equals(other.getCommentId()))
    && (this.getPid() == null ? other.getPid() == null : this.getPid().equals(other.getPid()))
    && (this.getArticleId() == null ? other.getArticleId() == null : this.getArticleId().equals(other.getArticleId()))
    && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
    && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
    && (this.getIp() == null ? other.getIp() == null : this.getIp().equals(other.getIp()))
    && (this.getAgent() == null ? other.getAgent() == null : this.getAgent().equals(other.getAgent()))
    && (this.getSystemId() == null ? other.getSystemId() == null : this.getSystemId().equals(other.getSystemId()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()))
    && (this.getContent() == null ? other.getContent() == null : this.getContent().equals(other.getContent()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  UcenterUser other = (UcenterUser) that;
  return (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
    && (this.getPassword() == null ? other.getPassword() == null : this.getPassword().equals(other.getPassword()))
    && (this.getSalt() == null ? other.getSalt() == null : this.getSalt().equals(other.getSalt()))
    && (this.getNickname() == null ? other.getNickname() == null : this.getNickname().equals(other.getNickname()))
    && (this.getSex() == null ? other.getSex() == null : this.getSex().equals(other.getSex()))
    && (this.getAvatar() == null ? other.getAvatar() == null : this.getAvatar().equals(other.getAvatar()))
    && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
    && (this.getCreateIp() == null ? other.getCreateIp() == null : this.getCreateIp().equals(other.getCreateIp()))
    && (this.getLastLoginTime() == null ? other.getLastLoginTime() == null : this.getLastLoginTime().equals(other.getLastLoginTime()))
    && (this.getLastLoginIp() == null ? other.getLastLoginIp() == null : this.getLastLoginIp().equals(other.getLastLoginIp()));
}

代码示例来源:origin: shuzheng/zheng

@Override
public boolean equals(Object that) {
  if (this == that) {
    return true;
  }
  if (that == null) {
    return false;
  }
  if (getClass() != that.getClass()) {
    return false;
  }
  UpmsSystem other = (UpmsSystem) that;
  return (this.getSystemId() == null ? other.getSystemId() == null : this.getSystemId().equals(other.getSystemId()))
    && (this.getIcon() == null ? other.getIcon() == null : this.getIcon().equals(other.getIcon()))
    && (this.getBanner() == null ? other.getBanner() == null : this.getBanner().equals(other.getBanner()))
    && (this.getTheme() == null ? other.getTheme() == null : this.getTheme().equals(other.getTheme()))
    && (this.getBasepath() == null ? other.getBasepath() == null : this.getBasepath().equals(other.getBasepath()))
    && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
    && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
    && (this.getTitle() == null ? other.getTitle() == null : this.getTitle().equals(other.getTitle()))
    && (this.getDescription() == null ? other.getDescription() == null : this.getDescription().equals(other.getDescription()))
    && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()))
    && (this.getOrders() == null ? other.getOrders() == null : this.getOrders().equals(other.getOrders()));
}

代码示例来源:origin: shuzheng/zheng

&& (this.getKeywords() == null ? other.getKeywords() == null : this.getKeywords().equals(other.getKeywords()))
&& (this.getDescription() == null ? other.getDescription() == null : this.getDescription().equals(other.getDescription()))
&& (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
&& (this.getAllowcomments() == null ? other.getAllowcomments() == null : this.getAllowcomments().equals(other.getAllowcomments()))
&& (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
&& (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
&& (this.getReadnumber() == null ? other.getReadnumber() == null : this.getReadnumber().equals(other.getReadnumber()))

代码示例来源:origin: MorphiaOrg/morphia

@Test
public void testByte() throws Exception {
  final ContainsByte cb = new ContainsByte();
  getDs().save(cb);
  final ContainsByte loaded = getDs().get(cb);
  assertNotNull(loaded);
  assertTrue(loaded.val0 == cb.val0);
  assertTrue(loaded.val1.equals(cb.val1));
}

相关文章