Documentation
¶
Index ¶
- Constants
- func AsignarPtr(a interface{}) interface{}
- func BytetoStr(str []byte) string
- func BytetoStrHex(str []byte) string
- func CleanStringJson(data string) string
- func DecodeBase64(s string) string
- func EncodeBase64(s string) string
- func Float64ToStr(val float64) string
- func Int32ToStr(val int32) string
- func Int64ToStr(val int64) string
- func IntToStr(val int) string
- func JSONStrObj(data string) ([]map[string]interface{}, error)
- func JSONtoObj(d JSON) ([]map[string]interface{}, error)
- func JsonStructMapData(data interface{}) (map[string]interface{}, error)
- func MapKeys(data *map[interface{}]interface{}) []interface{}
- func MapStrKeys(data *map[string]interface{}) []string
- func NewTicker(ft, tp string) (*time.Ticker, error)
- func ParseJSON(d JSON, v interface{}) error
- func PrintMap(format string, data map[string]interface{}) string
- func RoundFloat64(valor float64, dec int) float64
- func SliceStrToStr(strs []string, separador string) string
- func StrToFloat64(val string) (float64, error)
- func StrToInt32(val string) (int32, error)
- func StrToInt64(val string) (int64, error)
- func StringToDate(s string) (time.Time, error)
- func StrtoByte(str string) []byte
- func StrtoByteHex(str string) []byte
- func StructToMap(i interface{}) (valores url.Values)
- func TimetoStr(dia time.Time) string
- func ToBoolean(data interface{}) bool
- func ToDateStr(t time.Time) string
- func ToDateStrSingle(t time.Time) string
- func ToFloat(i interface{}) float32
- func ToFloat64(i interface{}) float64
- func ToInt(i interface{}) int
- func ToInt8(i interface{}) int8
- func ToInt16(i interface{}) int16
- func ToInt32(i interface{}) int32
- func ToInt64(i interface{}) int64
- func ToJsonMapStr(jsonStr string) (map[string]string, error)
- func ToMapInterface(i interface{}) (map[string]interface{}, error)
- func ToString(i interface{}) string
- func ToTime(data interface{}) (tim time.Time, err error)
- type Component
- func (p *Component) Add(data ...Component) *Component
- func (p *Component) Body(vladd string) *Component
- func (p *Component) Byte() []byte
- func (p *Component) HTML(styles string) *Component
- func (p *Component) Map(key string, data ...Component) *Component
- func (p *Component) Print(key string, data interface{}) *Component
- func (p *Component) PrintMap(data map[string]interface{}) *Component
- func (p *Component) String() string
- type Date
- type Float64XML
- type HrTime
- type JSON
Constants ¶
const (
/*FORMFE : Formato de fecha para los archivo YYYYMMDD*/
FORMFE = "%d%02d%02d"
)
Variables ¶
This section is empty.
Functions ¶
func AsignarPtr ¶
func AsignarPtr(a interface{}) interface{}
AsignarPtr : asigna la data despues de referencias en punteros muchas veces
func BytetoStrHex ¶
BytetoStrHex : Convierte un array byte a string
func CleanStringJson ¶ added in v1.0.9
CleanStringJson : limpia un string json de caracteres especiales
func DecodeBase64 ¶
DecodeBase64 : convierte un string base64 a string normal
func Float64ToStr ¶
Float64ToStr : Convierte un valor float64 a string.
func JSONStrObj ¶ added in v1.0.7
JSONtoObj : convierte un string a map
func JsonStructMapData ¶
JsonStructMapData : convierte un struct con tag json a map interface
func MapKeys ¶
func MapKeys(data *map[interface{}]interface{}) []interface{}
MapKeys : Conviert un map a interface o datos dinamicos.
func MapStrKeys ¶
MapStrKeys : Convierte un map a arreglo de string
func PrintMap ¶
PrintMap : formatea un string con un mapa de datos este mapa de datos debe colocar las variables con {var1} para ser reemplazado por el dato
func SliceStrToStr ¶
SliceStrToStr : convierte un array de strings a un string con separador
func StrToFloat64 ¶
StrToFloat64 : Convierte un valor string a float64.
func StrToInt32 ¶
StrToInt32 : Convierte un string a int32
func StrToInt64 ¶
StrToInt64 : Convierte un string a int64
func StringToDate ¶
StringToDate : convierte un string a un time
func StrtoByteHex ¶
StrtoByteHex : Convierte un string a array byte
func StructToMap ¶
StructToMap : Convierte un struct a map[string]
func TimetoStr ¶
TimetoStr : Convierte un time al string con el formato YYYYMMDD que esta en constante.
func ToDateStrSingle ¶
ToDateStrSingle : envia en formato largo un datetime YYYY-MM-DD
func ToJsonMapStr ¶ added in v1.0.7
ToJsonMapStr : convierte un string a map
func ToMapInterface ¶
ToMapInterface : convierte cualquier data en map [string]interface{}
Types ¶
type Component ¶
type Component string
Component : crea componentes literal
type Date ¶
Date : formato Time especial con parseo los xml y json de manera que el formato puede variar
func (*Date) UnmarshalJSON ¶
UnmarshalJSON : fomateo especial a json para los tipo Time en golang
func (*Date) UnmarshalXML ¶
UnmarshalXML : fomateo especial a xml para los tipo Time en golang
type Float64XML ¶
type Float64XML float64
Float64XML : tipo que repara el error de los xml en los millones
func (Float64XML) MarshalXMLAttr ¶
MarshalXMLAttr : tramforma el xml
type HrTime ¶
type HrTime struct {
// contains filtered or unexported fields
}
HrTime : valida las horas en un time
func NewHrTimeDate ¶
NewHrTimeDate : crea un time con un tipo date
func NewHrTimeStr ¶
NewHrTimeStr : crea un time con formato de hora 24hr ejemplo 24:00