- java.lang.Object
-
- com.github.alexdlaird.ngrok.protocol.Tunnel
-
public class Tunnel extends java.lang.Object
An object representing a Tunnel response fromngrok
's API.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Tunnel.Metrics
static class
Tunnel.TunnelConfig
-
Constructor Summary
Constructors Constructor Description Tunnel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tunnel.TunnelConfig
getConfig()
Get the tunnel config.java.lang.String
getId()
Get the ID of the tunnel.java.util.Map<java.lang.String,Tunnel.Metrics>
getMetrics()
Get the tunnel metrics.java.lang.String
getName()
Get the name of the tunnel.java.lang.String
getProto()
Get the proto of the tunnel.java.lang.String
getPublicUrl()
Get the public URL of the tunnel.java.lang.String
getUri()
Get the relative URI of the tunnel.void
setMetrics(java.util.Map<java.lang.String,Tunnel.Metrics> metrics)
Set tunnel metrics.void
setProto(java.lang.String proto)
Set tunnel proto.void
setPublicUrl(java.lang.String publicUrl)
Set the tunnel's public URL.
-
-
-
Method Detail
-
getId
public java.lang.String getId()
Get the ID of the tunnel.
-
getName
public java.lang.String getName()
Get the name of the tunnel.
-
getUri
public java.lang.String getUri()
Get the relative URI of the tunnel.
-
getPublicUrl
public java.lang.String getPublicUrl()
Get the public URL of the tunnel.
-
setPublicUrl
public void setPublicUrl(java.lang.String publicUrl)
Set the tunnel's public URL.- Parameters:
publicUrl
- The updated public URL.
-
getProto
public java.lang.String getProto()
Get the proto of the tunnel.
-
setProto
public void setProto(java.lang.String proto)
Set tunnel proto.- Parameters:
proto
- The updated proto.
-
getConfig
public Tunnel.TunnelConfig getConfig()
Get the tunnel config.
-
getMetrics
public java.util.Map<java.lang.String,Tunnel.Metrics> getMetrics()
Get the tunnel metrics.
-
setMetrics
public void setMetrics(java.util.Map<java.lang.String,Tunnel.Metrics> metrics)
Set tunnel metrics.- Parameters:
metrics
- The updated metrics.
-
-