v0.0.434
All checks were successful
Build Docker and Deploy / Run goext test-suite (push) Successful in 1m13s
All checks were successful
Build Docker and Deploy / Run goext test-suite (push) Successful in 1m13s
This commit is contained in:
parent
9321938dad
commit
f47e2a33fe
@ -1,5 +1,5 @@
|
||||
package goext
|
||||
|
||||
const GoextVersion = "0.0.433"
|
||||
const GoextVersion = "0.0.434"
|
||||
|
||||
const GoextVersionTimestamp = "2024-04-15T10:25:30+0200"
|
||||
const GoextVersionTimestamp = "2024-04-15T10:43:26+0200"
|
||||
|
@ -8,6 +8,7 @@ import (
|
||||
"go.mongodb.org/mongo-driver/bson/bsoncodec"
|
||||
"go.mongodb.org/mongo-driver/bson/bsonrw"
|
||||
"go.mongodb.org/mongo-driver/bson/bsontype"
|
||||
"gogs.mikescher.com/BlackForestBytes/goext/langext"
|
||||
"reflect"
|
||||
"time"
|
||||
)
|
||||
@ -245,6 +246,13 @@ func NewRFC3339(t time.Time) RFC3339Time {
|
||||
return RFC3339Time(t)
|
||||
}
|
||||
|
||||
func NewRFC3339Ptr(t *time.Time) *RFC3339Time {
|
||||
if t == nil {
|
||||
return nil
|
||||
}
|
||||
return langext.Ptr(RFC3339Time(*t))
|
||||
}
|
||||
|
||||
func NowRFC3339() RFC3339Time {
|
||||
return RFC3339Time(time.Now())
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import (
|
||||
"go.mongodb.org/mongo-driver/bson/bsoncodec"
|
||||
"go.mongodb.org/mongo-driver/bson/bsonrw"
|
||||
"go.mongodb.org/mongo-driver/bson/bsontype"
|
||||
"gogs.mikescher.com/BlackForestBytes/goext/langext"
|
||||
"reflect"
|
||||
"time"
|
||||
)
|
||||
@ -245,6 +246,13 @@ func NewRFC3339Nano(t time.Time) RFC3339NanoTime {
|
||||
return RFC3339NanoTime(t)
|
||||
}
|
||||
|
||||
func NewRFC3339NanoPtr(t *time.Time) *RFC3339NanoTime {
|
||||
if t == nil {
|
||||
return nil
|
||||
}
|
||||
return langext.Ptr(RFC3339NanoTime(*t))
|
||||
}
|
||||
|
||||
func NowRFC3339Nano() RFC3339NanoTime {
|
||||
return RFC3339NanoTime(time.Now())
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import (
|
||||
"go.mongodb.org/mongo-driver/bson/bsoncodec"
|
||||
"go.mongodb.org/mongo-driver/bson/bsonrw"
|
||||
"go.mongodb.org/mongo-driver/bson/bsontype"
|
||||
"gogs.mikescher.com/BlackForestBytes/goext/langext"
|
||||
"reflect"
|
||||
"strconv"
|
||||
"time"
|
||||
@ -239,6 +240,13 @@ func NewUnix(t time.Time) UnixTime {
|
||||
return UnixTime(t)
|
||||
}
|
||||
|
||||
func NewUnixPtr(t *time.Time) *UnixTime {
|
||||
if t == nil {
|
||||
return nil
|
||||
}
|
||||
return langext.Ptr(UnixTime(*t))
|
||||
}
|
||||
|
||||
func NowUnix() UnixTime {
|
||||
return UnixTime(time.Now())
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import (
|
||||
"go.mongodb.org/mongo-driver/bson/bsoncodec"
|
||||
"go.mongodb.org/mongo-driver/bson/bsonrw"
|
||||
"go.mongodb.org/mongo-driver/bson/bsontype"
|
||||
"gogs.mikescher.com/BlackForestBytes/goext/langext"
|
||||
"reflect"
|
||||
"strconv"
|
||||
"time"
|
||||
@ -239,6 +240,13 @@ func NewUnixMilli(t time.Time) UnixMilliTime {
|
||||
return UnixMilliTime(t)
|
||||
}
|
||||
|
||||
func NewUnixMilliPtr(t *time.Time) *UnixMilliTime {
|
||||
if t == nil {
|
||||
return nil
|
||||
}
|
||||
return langext.Ptr(UnixMilliTime(*t))
|
||||
}
|
||||
|
||||
func NowUnixMilli() UnixMilliTime {
|
||||
return UnixMilliTime(time.Now())
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import (
|
||||
"go.mongodb.org/mongo-driver/bson/bsoncodec"
|
||||
"go.mongodb.org/mongo-driver/bson/bsonrw"
|
||||
"go.mongodb.org/mongo-driver/bson/bsontype"
|
||||
"gogs.mikescher.com/BlackForestBytes/goext/langext"
|
||||
"reflect"
|
||||
"strconv"
|
||||
"time"
|
||||
@ -239,6 +240,13 @@ func NewUnixNano(t time.Time) UnixNanoTime {
|
||||
return UnixNanoTime(t)
|
||||
}
|
||||
|
||||
func NewUnixNanoPtr(t *time.Time) *UnixNanoTime {
|
||||
if t == nil {
|
||||
return nil
|
||||
}
|
||||
return langext.Ptr(UnixNanoTime(*t))
|
||||
}
|
||||
|
||||
func NowUnixNano() UnixNanoTime {
|
||||
return UnixNanoTime(time.Now())
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user