Documentation ¶
Index ¶
- Constants
- Variables
- func A(a ...interface{}) []interface{}
- func A0(a ...interface{}) interface{}
- func AbcF(a float64) float64
- func AbcI(a int) int
- func AboutVersion(version string)
- func AppExit(code int)
- func AppHasArg(v string) bool
- func AppProcessID() int
- func AppRunArgs() []string
- func B2S(v bool, str_true string, str_false string) string
- func B2S_10(v bool) string
- func B2S_TF(v bool) string
- func B2S_YN(v bool) string
- func BlendColors(argb_back [4]float64, argb_over [4]float64, maxv float64) [4]int
- func ByteCountBinary(b int64) string
- func ChanGetOrSkip(ch chan interface{}) (interface{}, bool)
- func CloneBytesArray(arr []byte) []byte
- func CompareBoolLess(a bool, b bool) bool
- func Crypto_MD5(data []byte) string
- func Crypto_SHA1(data []byte) string
- func ErrorWithText(txt string) error
- func ExecCommand(exe_name string, args ...string) (string, string, string)
- func ExecCommandBytes(input []byte, timeout_ms int, forkill chan *exec.Cmd, exe_name string, ...) ([]byte, []byte, string)
- func ExecQuote(s string) string
- func F2S(v float64, prec int) string
- func FileBytesRead(fname string) (*[]byte, bool)
- func FileBytesWrite(fname string, bytedata *[]byte, executable bool) bool
- func FileCopyAtom(src string, dst string, copied *AInt64, buffer_size int) error
- func FileDelete(path string) bool
- func FileEvalSymlinks(fullpath string) (string, error)
- func FileExists(name string) bool
- func FileExtension(filename string) string
- func FileFindFreeName(folderpath string, filename string, copylabel string, ext string) string
- func FileIsLink(f os.FileInfo) bool
- func FileLinkIsDir(fullname string) bool
- func FileMake(pathname string) bool
- func FileNameForCopy(path_dst string, copy_label string, isdir bool) string
- func FilePathEndSlashRemove(filepath string) string
- func FilePermissionsString(name string) string
- func FileRename(path_src string, path_dst string) (bool, string)
- func FileSeparateNumberedName(filename string, copylabel string, isdir bool) (string, string)
- func FileSizeNiceString(b int64) string
- func FileSortName(filename string) string
- func FileSplitPathAndName(filename string) (string, string)
- func FileTextRead(name string) (string, bool)
- func FileTextWrite(fname string, data string) bool
- func FileToCodeGenerator(fname string, ftype string, funcffix string) string
- func FolderLocation_App() string
- func FolderLocation_UserHome() string
- func FolderLocation_WorkDir() string
- func FolderMake(pathname string) bool
- func FolderPathEndSlash(path string) string
- func FoldersRecursively_Copy(mount_list [][2]string, file_or_dir os.FileInfo, path_src_real string, ...) string
- func FoldersRecursively_Delete(mount_list [][2]string, file_or_dir os.FileInfo, path_real string, ...)
- func FoldersRecursively_Move(mount_list [][2]string, file_or_dir os.FileInfo, path_src_real string, ...) (string, bool)
- func FoldersRecursively_Search(mount_list [][2]string, dir os.FileInfo, path_real string, search string, ...)
- func FoldersRecursively_Search_Default(str string) string
- func FoldersRecursively_Size(mount_list [][2]string, file_or_dir os.FileInfo, path_real string, ...)
- func FoldersRecursively_Walk(mount_list [][2]string, file_or_dir os.FileInfo, path_src_real string, ...)
- func FreeOSMemory()
- func GarbageCollection()
- func GetGolangVersion() string
- func GetOS() int
- func GetOS_Bits() int
- func GetOS_Name() string
- func GetOS_Slash() string
- func GetPC() string
- func GetPC_CountCores() int
- func GetPC_MemoryUsageMb() float64
- func GetPC_UserUidLoginName() (string, string, string)
- func GoId() int
- func HtmlEscape(str string) string
- func I2S(v int) string
- func I2S64(v int64) string
- func I2Ss(v int64) string
- func ImageAddOver(img1 *image.RGBA, img2 image.Image, x int, y int)
- func ImageClone(img image.Image) *image.RGBA
- func ImageDecode(data *[]byte) image.Image
- func ImageDecodeCustom(data *[]byte, customdecoder func(io.Reader) (image.Image, string, error)) image.Image
- func ImageDecodeRGBA(data *[]byte, colorTransperent color.RGBA) *image.RGBA
- func ImageGrayScale(img image.Image) *image.Gray
- func ImageResizeHalfNice(img *image.RGBA) *image.RGBA
- func ImageResizeNearest(img image.Image, w int, h int) *image.RGBA
- func ImageSubImage(big image.Image, x0, y0, x1, y1 int) *image.RGBA
- func ImageToCode(fname string, funcffix string) string
- func InfiniteLoop()
- func Int32Bytes(v int32) [4]byte
- func IntInArray(val int, array []int) int
- func InterfaceNil(a interface{}) bool
- func IsInt(v string) bool
- func Log_TestFailed(t *testing.T)
- func Log_TypeDetail(t interface{}) string
- func Log_TypeOf(v interface{}) string
- func Log_WhereAmI() string
- func MAXF(a float64, b float64) float64
- func MAXI(a int, b int) int
- func MAXI64(a int64, b int64) int64
- func MINF(a float64, b float64) float64
- func MINI(a int, b int) int
- func MINI64(a int64, b int64) int64
- func NetLocalAddr()
- func NetPortIsFree(port int, timeout_milliseconds int) bool
- func NetPostUrl(url string) (string, error)
- func NetReadUrlText(url string) (string, error)
- func Prln(v string)
- func RandInt(min int, max int) int
- func RandNew()
- func RoundF(a float64) int
- func RuntimeGoMaxProcs(num int)
- func RuntimeGosched()
- func RuntimeLockOSThread()
- func RuntimeSetFinalizer(obj interface{}, finalFunc interface{})
- func S2F(v string) float64
- func S2I(v string) int
- func S2I64(v string) int64
- func Scln() string
- func Select_Int(condition bool, istrue int, isfalse int) int
- func SleepMS(ms int)
- func SortArray(slice interface{}, less func(i, j int) bool)
- func Sqrt(x float64) float64
- func StringClip(str string, maxlen int) string
- func StringCommonPrefix(a string, b string) string
- func StringCommonPrefixArr(a []string) string
- func StringDown(str string) string
- func StringEnd(str string, count int) string
- func StringFill(str string, length int) string
- func StringFilter(str string, reg RegExp) string
- func StringFind(where string, what string) int
- func StringFindEnd(where string, what string) int
- func StringFixUTF8(line string) string
- func StringFormat(format string, args ...interface{}) string
- func StringInArray(val string, array []string) int
- func StringJoin(target []string, separator string) string
- func StringLength(str string) int
- func StringPart(str string, start int, end int) string
- func StringRemoveDoubleChar(str string, one_char string) string
- func StringReplace(str string, from string, to string) string
- func StringSplit(target string, separator string) []string
- func StringSplitLines(target string) []string
- func StringTitle(str string) string
- func StringTrim(str string) string
- func StringUp(str string) string
- func TimeGolang(t Time) time.Time
- func TimeIsSorted(time1 Time, time2 Time) bool
- func TimeNowStr() string
- func TimeSeconds(start Time) float64
- func TimeSecondsSub(start Time, finished Time) float64
- func TimeStr(t Time, seconds bool) string
- func TimeWeekday(t Time) int
- func Unzip(src string, dest string) ([]string, error)
- func UrlQueryEscape(urlstr string) string
- func UrlQueryParse(urlstr string) (url.Values, error)
- func UrlQueryUnescape(urlstr string) string
- func XOR(X bool, Y bool) bool
- type ABool
- type AFloat
- type AInt
- type AInt64
- type AString
- type FileInteractiveRequest
- type FileInteractiveResponse
- type FileReport
- type FuncArr
- type IFolderWalker
- type LangArr
- type Log
- type OptionsStorage
- func (s *OptionsStorage) AddRecord_Array(order int, key string, value_default string, values_allowed []string, ...)
- func (s *OptionsStorage) AddRecord_Boolean(order int, key string, value_default bool, key_comment string)
- func (s *OptionsStorage) AddRecord_Integer(order int, key string, value_default int, value_min int, value_max int, ...)
- func (s *OptionsStorage) AddRecord_String(order int, key string, value_default string, key_comment string)
- func (s *OptionsStorage) GetRecordComment(key string) string
- func (s *OptionsStorage) GetRecordMinMaxStep(key string) (float64, float64, float64)
- func (s *OptionsStorage) GetRecordTitlesArray(key string) []string
- func (s *OptionsStorage) GetRecordType(key string) string
- func (s *OptionsStorage) GetRecordValuesArray(key string) []string
- func (s *OptionsStorage) GetRecordsKeys() []string
- func (s *OptionsStorage) RecordsValues_Load(fname string)
- func (s *OptionsStorage) RecordsValues_Save(fname string)
- func (s *OptionsStorage) ValueGetArrayIndex(key string) int
- func (s *OptionsStorage) ValueGetBoolean(key string) bool
- func (s *OptionsStorage) ValueGetInteger(key string) int
- func (s *OptionsStorage) ValueGetString(key string) string
- func (s *OptionsStorage) ValueSetArrayIndex(key string, value int)
- func (s *OptionsStorage) ValueSetBoolean(key string, value bool)
- func (s *OptionsStorage) ValueSetInteger(key string, value int)
- func (s *OptionsStorage) ValueSetString(key string, value string)
- type OptionsStorageItem
- type RegExp
- type SyncMutex
- type SyncMutexRW
- type SyncMutexRW_OneWriterProtected
- type SyncOnce
- type SyncQueue
- type SyncWaitGroup
- type Time
Constants ¶
View Source
const BytesInMb uint64 = 1024 * 1024
View Source
const COPY_LABEL = "copy"
View Source
const DEFAULT_FILE_PERMISSION os.FileMode = 776
View Source
const DEFAULT_FILE_PERMISSION_RUN os.FileMode = 777
View Source
const DEFAULT_LANG = "en"
View Source
const FILE_COMMENT = "#"
View Source
const FILE_INTERACTIVE_ASK_ERROR = 1
View Source
const FILE_INTERACTIVE_ASK_EXIST = 0
View Source
const FILE_INTERACTIVE_ASK_PANIC = 2
View Source
const FILE_INTERACTIVE_NEWNAME = "newname"
View Source
const FILE_INTERACTIVE_REPLACE = "replace"
View Source
const FILE_INTERACTIVE_RETRY = "retry"
View Source
const FILE_INTERACTIVE_SKIP = "skip"
View Source
const INT_SEPARATOR = ' '
View Source
const MAX_A = 65535 / 255 //?
View Source
const OPTIONS_TYPE_ARRAY = "Array"
View Source
const OPTIONS_TYPE_ARRAY_CODED = "ArrayCoded"
View Source
const OPTIONS_TYPE_BOOLEAN = "Boolean"
View Source
const OPTIONS_TYPE_INTEGER = "Integer"
View Source
const OPTIONS_TYPE_STRING = "String"
View Source
const OS_LINUX = 3
View Source
const OS_MAC = 2
View Source
const OS_WINDOWS = 1
Variables ¶
View Source
var END_SLASH = ""
Functions ¶
func A ¶
func A(a ...interface{}) []interface{}
if a, b, c = func() and you need only "b" or only "c"
func AboutVersion ¶
func AboutVersion(version string)
func AppProcessID ¶
func AppProcessID() int
func AppRunArgs ¶
func AppRunArgs() []string
func BlendColors ¶
func ByteCountBinary ¶
func ChanGetOrSkip ¶
func ChanGetOrSkip(ch chan interface{}) (interface{}, bool)
func CloneBytesArray ¶
func Crypto_MD5 ¶
func Crypto_SHA1 ¶
func ErrorWithText ¶
func ExecCommandBytes ¶
func FileBytesRead ¶
func FileCopyAtom ¶
func FileDelete ¶
func FileEvalSymlinks ¶
func FileExists ¶
func FileExtension ¶
func FileFindFreeName ¶
func FileIsLink ¶
func FileLinkIsDir ¶
func FilePathEndSlashRemove ¶
func FilePermissionsString ¶
func FileSizeNiceString ¶
func FileSortName ¶
func FileSplitPathAndName ¶
func FileTextRead ¶
func FileTextWrite ¶
func FileToCodeGenerator ¶
func FolderLocation_App ¶
func FolderLocation_App() string
func FolderLocation_UserHome ¶
func FolderLocation_UserHome() string
func FolderLocation_WorkDir ¶
func FolderLocation_WorkDir() string
func FolderMake ¶
func FolderPathEndSlash ¶
func FoldersRecursively_Copy ¶
func FoldersRecursively_Copy(mount_list [][2]string, file_or_dir os.FileInfo, path_src_real string, path_dst_real string, counter_size *AInt64, counter_files_done *AInt64, buffer int, chan_cmd chan FileInteractiveResponse, chan_ask chan FileInteractiveRequest, current_file *AString, cmd_saved string) string
func FoldersRecursively_Move ¶
func FoldersRecursively_Move(mount_list [][2]string, file_or_dir os.FileInfo, path_src_real string, path_dst_real string, counter_size *AInt64, counter_files_done *AInt64, buffer int, chan_cmd chan FileInteractiveResponse, chan_ask chan FileInteractiveRequest, current_file *AString, cmd_saved string, disk_equal bool) (string, bool)
func FoldersRecursively_Size ¶
func FoldersRecursively_Walk ¶
func FreeOSMemory ¶
func FreeOSMemory()
func GarbageCollection ¶
func GarbageCollection()
func GetGolangVersion ¶
func GetGolangVersion() string
func GetOS_Bits ¶
func GetOS_Bits() int
func GetOS_Name ¶
func GetOS_Name() string
func GetOS_Slash ¶
func GetOS_Slash() string
func GetPC_CountCores ¶
func GetPC_CountCores() int
func GetPC_UserUidLoginName ¶
func HtmlEscape ¶
func ImageDecode ¶
func ImageDecodeCustom ¶
func ImageDecodeCustom(data *[]byte, customdecoder func(io.Reader) (image.Image, string, error)) image.Image
github.com/disintegration/imageorient - imageorient.Decode()
func ImageToCode ¶
func InfiniteLoop ¶
func InfiniteLoop()
func Int32Bytes ¶
func IntInArray ¶
func InterfaceNil ¶
func InterfaceNil(a interface{}) bool
func Log_TestFailed ¶
func Log_TypeDetail ¶
func Log_TypeDetail(t interface{}) string
func Log_TypeOf ¶
func Log_TypeOf(v interface{}) string
func Log_WhereAmI ¶
func Log_WhereAmI() string
func NetLocalAddr ¶
func NetLocalAddr()
func NetPortIsFree ¶
func NetPostUrl ¶
func NetReadUrlText ¶
func RuntimeGoMaxProcs ¶
func RuntimeGoMaxProcs(num int)
func RuntimeGosched ¶
func RuntimeGosched()
func RuntimeLockOSThread ¶
func RuntimeLockOSThread()
func RuntimeSetFinalizer ¶
func RuntimeSetFinalizer(obj interface{}, finalFunc interface{})
func StringClip ¶
func StringCommonPrefix ¶
func StringCommonPrefixArr ¶
func StringDown ¶
func StringFill ¶
func StringFilter ¶
func StringFixUTF8 ¶
func StringFormat ¶
func StringInArray ¶
func StringJoin ¶
func StringLength ¶
func StringPart ¶
result from 1, end can be 0
func StringRemoveDoubleChar ¶
func StringSplit ¶
func StringSplitLines ¶
func StringTitle ¶
func StringTrim ¶
func TimeGolang ¶
func TimeIsSorted ¶
func TimeNowStr ¶
func TimeNowStr() string
func TimeSeconds ¶
func TimeSecondsSub ¶
func TimeWeekday ¶
func UrlQueryEscape ¶
func UrlQueryUnescape ¶
Types ¶
type ABool ¶
type ABool struct {
// contains filtered or unexported fields
}
func NewAtomicBool ¶
func NewAtomicBoolTxt ¶
type AFloat ¶
type AFloat struct {
// contains filtered or unexported fields
}
func NewAtomicFloat ¶
type AInt64 ¶
type AInt64 struct {
// contains filtered or unexported fields
}
func NewAtomicInt64 ¶
type AString ¶
type AString struct {
// contains filtered or unexported fields
}
func NewAtomicString ¶
type FileInteractiveRequest ¶
type FileInteractiveResponse ¶
type FileReport ¶
type FileReport struct { Path string NameOnly string FullName string IsRegular bool IsDirectory bool IsLink bool SizeBytes int64 // contains filtered or unexported fields }
func FileInfo ¶
func FileInfo(fullname string, fixlinks_isdir bool) (FileReport, error)
'os.Lstat()' reads the link itself. 'os.Stat()' would read the link's target.
func Folder_ListFiles ¶
func Folder_ListFiles(dirname string, fixlinks_isdir bool) ([]FileReport, error)
func NewFileReport ¶
func NewFileReport(fi os.FileInfo, path string, fixlinks_isdir bool) FileReport
func (FileReport) IsDir ¶
func (fr FileReport) IsDir() bool
func (FileReport) ModTime ¶
func (fr FileReport) ModTime() time.Time
func (FileReport) Mode ¶
func (fr FileReport) Mode() os.FileMode
func (FileReport) Name ¶
func (fr FileReport) Name() string
func (*FileReport) SetModeTime ¶
func (fr *FileReport) SetModeTime(mode string, modTime Time)
func (FileReport) Size ¶
func (fr FileReport) Size() int64
func (FileReport) Sys ¶
func (fr FileReport) Sys() interface{}
type FuncArr ¶
type FuncArr struct {
// contains filtered or unexported fields
}
func NewFuncArr ¶
func NewFuncArr() *FuncArr
type IFolderWalker ¶
type IFolderWalker interface { WithFile(f os.FileInfo, regular bool, path_src string, path_dst string) WithFolderBefore(f os.FileInfo, is_mount bool, path_src string, path_dst string, deep int) (string, bool) WithFolderAfter(f os.FileInfo, is_mount bool, list_err bool, path_src string, path_dst string) WithLink(f os.FileInfo, is_folder bool, path_src string, path_dst string) bool }
type LangArr ¶
type LangArr struct {
// contains filtered or unexported fields
}
func LangArrNew ¶
func (*LangArr) GetLangsCodes ¶
func (*LangArr) GetLangsTitles ¶
type OptionsStorage ¶
type OptionsStorage struct {
// contains filtered or unexported fields
}
func NewOptionsStorage ¶
func NewOptionsStorage() *OptionsStorage
func (*OptionsStorage) AddRecord_Array ¶
func (*OptionsStorage) AddRecord_Boolean ¶
func (s *OptionsStorage) AddRecord_Boolean(order int, key string, value_default bool, key_comment string)
func (*OptionsStorage) AddRecord_Integer ¶
func (*OptionsStorage) AddRecord_String ¶
func (s *OptionsStorage) AddRecord_String(order int, key string, value_default string, key_comment string)
func (*OptionsStorage) GetRecordComment ¶
func (s *OptionsStorage) GetRecordComment(key string) string
func (*OptionsStorage) GetRecordMinMaxStep ¶
func (s *OptionsStorage) GetRecordMinMaxStep(key string) (float64, float64, float64)
func (*OptionsStorage) GetRecordTitlesArray ¶
func (s *OptionsStorage) GetRecordTitlesArray(key string) []string
func (*OptionsStorage) GetRecordType ¶
func (s *OptionsStorage) GetRecordType(key string) string
func (*OptionsStorage) GetRecordValuesArray ¶
func (s *OptionsStorage) GetRecordValuesArray(key string) []string
func (*OptionsStorage) GetRecordsKeys ¶
func (s *OptionsStorage) GetRecordsKeys() []string
func (*OptionsStorage) RecordsValues_Load ¶
func (s *OptionsStorage) RecordsValues_Load(fname string)
func (*OptionsStorage) RecordsValues_Save ¶
func (s *OptionsStorage) RecordsValues_Save(fname string)
func (*OptionsStorage) ValueGetArrayIndex ¶
func (s *OptionsStorage) ValueGetArrayIndex(key string) int
func (*OptionsStorage) ValueGetBoolean ¶
func (s *OptionsStorage) ValueGetBoolean(key string) bool
func (*OptionsStorage) ValueGetInteger ¶
func (s *OptionsStorage) ValueGetInteger(key string) int
func (*OptionsStorage) ValueGetString ¶
func (s *OptionsStorage) ValueGetString(key string) string
func (*OptionsStorage) ValueSetArrayIndex ¶
func (s *OptionsStorage) ValueSetArrayIndex(key string, value int)
func (*OptionsStorage) ValueSetBoolean ¶
func (s *OptionsStorage) ValueSetBoolean(key string, value bool)
func (*OptionsStorage) ValueSetInteger ¶
func (s *OptionsStorage) ValueSetInteger(key string, value int)
func (*OptionsStorage) ValueSetString ¶
func (s *OptionsStorage) ValueSetString(key string, value string)
type OptionsStorageItem ¶
type OptionsStorageItem struct {
// contains filtered or unexported fields
}
type RegExp ¶
type RegExp struct {
// contains filtered or unexported fields
}
func StringFilterCompile ¶
type SyncMutex ¶
type SyncMutex struct {
// contains filtered or unexported fields
}
func NewSyncMutex ¶
func NewSyncMutex() *SyncMutex
type SyncMutexRW ¶
type SyncMutexRW struct {
// contains filtered or unexported fields
}
func NewSyncMutexRW ¶
func NewSyncMutexRW() *SyncMutexRW
func (*SyncMutexRW) R_Lock ¶
func (s *SyncMutexRW) R_Lock()
func (*SyncMutexRW) R_Unlock ¶
func (s *SyncMutexRW) R_Unlock()
func (*SyncMutexRW) W_Lock ¶
func (s *SyncMutexRW) W_Lock()
func (*SyncMutexRW) W_Unlock ¶
func (s *SyncMutexRW) W_Unlock()
type SyncMutexRW_OneWriterProtected ¶
type SyncMutexRW_OneWriterProtected struct {
// contains filtered or unexported fields
}
func NewSyncMutexRW_OneWriterProtected ¶
func NewSyncMutexRW_OneWriterProtected() *SyncMutexRW_OneWriterProtected
func (*SyncMutexRW_OneWriterProtected) R_Lock ¶
func (s *SyncMutexRW_OneWriterProtected) R_Lock()
func (*SyncMutexRW_OneWriterProtected) R_Unlock ¶
func (s *SyncMutexRW_OneWriterProtected) R_Unlock()
func (*SyncMutexRW_OneWriterProtected) W_Lock ¶
func (s *SyncMutexRW_OneWriterProtected) W_Lock()
func (*SyncMutexRW_OneWriterProtected) W_Unlock ¶
func (s *SyncMutexRW_OneWriterProtected) W_Unlock()
type SyncQueue ¶
type SyncQueue struct {
// contains filtered or unexported fields
}
https://github.com/sheerun/queue/blob/master/queue.go
func NewSyncQueue ¶
func NewSyncQueue() *SyncQueue
type SyncWaitGroup ¶
type SyncWaitGroup struct {
// contains filtered or unexported fields
}
func NewSyncWaitGroup ¶
func NewSyncWaitGroup() *SyncWaitGroup
func (*SyncWaitGroup) Add ¶
func (s *SyncWaitGroup) Add(delta int)
func (*SyncWaitGroup) Done ¶
func (s *SyncWaitGroup) Done()
func (*SyncWaitGroup) Wait ¶
func (s *SyncWaitGroup) Wait()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.