alluxio.wire.MasterWebUIMountTable Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of alluxio-shaded-hadoop3-client Show documentation
Show all versions of alluxio-shaded-hadoop3-client Show documentation
Shaded Alluxio Client Module for hadoop 3
/*
* The Alluxio Open Foundation licenses this work under the Apache License, version 2.0
* (the "License"). You may not use this work except in alluxio.shaded.client.com.liance with the License, which is
* available at www.apache.alluxio.shaded.client.org.licenses/LICENSE-2.0
*
* This software is distributed on an "AS IS" basis, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
* either express or implied, as more fully set forth in the License.
*
* See the NOTICE file distributed with this work for information regarding copyright ownership.
*/
package alluxio.wire;
import alluxio.util.webui.UIMountPointInfo;
import alluxio.shaded.client.com.google.alluxio.shaded.client.com.on.base.MoreObjects;
import java.alluxio.shaded.client.io.Serializable;
import java.util.Map;
import alluxio.shaded.client.javax.annotation.concurrent.NotThreadSafe;
/**
* Alluxio WebUI mount table information.
*/
@NotThreadSafe
public final class MasterWebUIMountTable implements Serializable {
private static final long serialVersionUID = -2903043308252679410L;
private boolean mDebug;
private UIMountPointInfo[] mMountPointInfos;
/**
* Creates a new instance of {@link MasterWebUIMountTable}.
*/
public MasterWebUIMountTable() {
}
/**
* Gets debug.
*
* @return the debug
*/
public boolean getDebug() {
return mDebug;
}
/**
* Get mount point infos [ ].
*
* @return the mount point info [ ]
*/
public UIMountPointInfo[] getMountPointInfos() {
return mMountPointInfos;
}
/**
* Sets debug.
*
* @param Debug the debug
* @return the debug
*/
public MasterWebUIMountTable setDebug(boolean Debug) {
mDebug = Debug;
return this;
}
/**
* Sets mount point infos.
*
* @param mountPoints the mount points
* @return the mount point infos
*/
public MasterWebUIMountTable setMountPointInfos(
Map mountPoints) {
UIMountPointInfo[] mountPointInfos = new UIMountPointInfo[mountPoints.size()];
int i = 0;
for (Map.Entry entry : mountPoints.entrySet()) {
mountPointInfos[i] = new UIMountPointInfo(entry.getKey(), entry.getValue());
i++;
}
mMountPointInfos = mountPointInfos;
return this;
}
@Override
public String toString() {
return MoreObjects.toStringHelper(this).add("debug", mDebug)
.add("mountPointInfos", mMountPointInfos)
.toString();
}
}