aboutsummaryrefslogtreecommitdiff
path: root/ipmask.go
diff options
context:
space:
mode:
authorspf13 <[email protected]>2014-07-11 10:25:27 -0400
committerspf13 <[email protected]>2014-07-11 10:25:27 -0400
commit463bdc838f2b35e9307e91d480878bda5fff7232 (patch)
treecb01b60a27df6601aa01c06791bec65e0c2674b4 /ipmask.go
parentb02196a78893a71903e9ad98359e7f891b1e7781 (diff)
Adding Type() method to the values.
Diffstat (limited to 'ipmask.go')
-rw-r--r--ipmask.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/ipmask.go b/ipmask.go
index b8a164a..6f85be9 100644
--- a/ipmask.go
+++ b/ipmask.go
@@ -26,6 +26,10 @@ func (i *ipMaskValue) Get() interface{} {
return net.IPMask(*i)
}
+func (i *ipMaskValue) Type() string {
+ return "ipMask"
+}
+
// Parse IPv4 netmask written in IP form (e.g. 255.255.255.0).
// This function should really belong to the net package.
func ParseIPv4Mask(s string) net.IPMask {