List of usage examples for com.google.common.collect Lists asList
public static <E> List<E> asList(@Nullable E first, E[] rest)
From source file:org.apache.hadoop.hive.ql.optimizer.calcite.HiveSubQRemoveRelBuilder.java
/** Creates a {@link org.apache.calcite.rel.core.Join}. */ public HiveSubQRemoveRelBuilder join(JoinRelType joinType, RexNode condition0, RexNode... conditions) { return join(joinType, Lists.asList(condition0, conditions)); }
From source file:org.apache.calcite.tools.RelBuilder.java
/** Creates a {@link org.apache.calcite.rel.core.Join}. */ public RelBuilder join(JoinRelType joinType, RexNode condition0, RexNode... conditions) { return join(joinType, Lists.asList(condition0, conditions)); }
From source file:org.apache.hadoop.hbase.security.access.AccessController.java
private void isSystemOrSuperUser(Configuration conf) throws IOException { User user = userProvider.getCurrent(); if (user == null) { throw new IOException("Unable to obtain the current user, " + "authorization checks for internal operations will not work correctly!"); }/*from w w w. j a v a2 s . co m*/ String currentUser = user.getShortName(); List<String> superusers = Lists.asList(currentUser, conf.getStrings(AccessControlLists.SUPERUSER_CONF_KEY, new String[0])); User activeUser = getActiveUser(); if (!(superusers.contains(activeUser.getShortName()))) { throw new AccessDeniedException( "User '" + (user != null ? user.getShortName() : "null") + "is not system or super user."); } }