hudson.model.User.getProperties()方法的使用及代码示例

x33g5p2x  于2022-01-31 转载在 其他  
字(2.4k)|赞(0)|评价(0)|浏览(85)

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

User.getProperties介绍

[英]Gets the user properties configured for this user.
[中]获取为此用户配置的用户属性。

代码示例

代码示例来源:origin: jenkinsci/jenkins

/**
 * Return all properties that are also actions.
 *
 * @return the list can be empty but never null. read only.
 */
public List<Action> getPropertyActions() {
  List<Action> actions = new ArrayList<>();
  for (UserProperty userProp : getProperties().values()) {
    if (userProp instanceof Action) {
      actions.add((Action) userProp);
    }
  }
  return Collections.unmodifiableList(actions);
}

代码示例来源:origin: org.jenkins-ci.main/jenkins-core

/**
 * Return all properties that are also actions.
 * 
 * @return the list can be empty but never null. read only.
 */
public List<Action> getPropertyActions() {
  List<Action> actions = new ArrayList<Action>();
  for (UserProperty userProp : getProperties().values()) {
    if (userProp instanceof Action) {
      actions.add((Action) userProp);
    }
  }
  return Collections.unmodifiableList(actions);
}

代码示例来源:origin: jenkinsci/ircbot-plugin

@Override
protected String getConfiguredIMId(User user) {
  IrcUserProperty ircUserProperty = (IrcUserProperty) user.getProperties().get(IrcUserProperty.DESCRIPTOR);
  if (ircUserProperty != null) {
    return ircUserProperty.getNick();
  }
  return null;
}

代码示例来源:origin: hudson/hudson-2.x

public Object getDynamic(String token) {
    for (UserProperty property: getProperties().values()) {
      if (property instanceof Action) {
        Action a= (Action) property;
      if(a.getUrlName().equals(token) || a.getUrlName().equals('/'+token))
        return a;
      }
    }
    return null;
  }
}

代码示例来源:origin: org.eclipse.hudson.main/hudson-core

public Object getDynamic(String token) {
    for (UserProperty property: getProperties().values()) {
      if (property instanceof Action) {
        Action a= (Action) property;
      if(a.getUrlName().equals(token) || a.getUrlName().equals('/'+token))
        return a;
      }
    }
    return null;
  }
}

代码示例来源:origin: org.eclipse.hudson/hudson-core

public Object getDynamic(String token) {
    for (UserProperty property : getProperties().values()) {
      if (property instanceof Action) {
        Action a = (Action) property;
        if (a.getUrlName().equals(token) || a.getUrlName().equals('/' + token)) {
          return a;
        }
      }
    }
    return null;
  }
}

代码示例来源:origin: org.jvnet.hudson.main/hudson-core

public Object getDynamic(String token) {
    for (UserProperty property: getProperties().values()) {
      if (property instanceof Action) {
        Action a= (Action) property;
      if(a.getUrlName().equals(token) || a.getUrlName().equals('/'+token))
        return a;
      }
    }
    return null;
  }
}

相关文章