(format string)
| 37 | } |
| 38 | |
| 39 | func (this *PointArg) SetFlagsFormat(format string) { |
| 40 | var p argtype.IArgType |
| 41 | switch format { |
| 42 | case "inotify_flags": |
| 43 | p = argtype.NewNumFlags(this.TypeIndex, argtype.InotifyFlagsConfig) |
| 44 | case "access_flags": |
| 45 | p = argtype.NewNumFlags(this.TypeIndex, argtype.AccessFlagsConfig) |
| 46 | case "mmap_flags": |
| 47 | p = argtype.NewNumFlags(this.TypeIndex, argtype.MMapFlagsConfig) |
| 48 | case "mremap_flags": |
| 49 | p = argtype.NewNumFlags(this.TypeIndex, argtype.MremapFlagsConfig) |
| 50 | case "file_flags": |
| 51 | p = argtype.NewNumFlags(this.TypeIndex, argtype.FileFlagsConfig) |
| 52 | case "prot_flags": |
| 53 | p = argtype.NewNumFlags(this.TypeIndex, argtype.ProtFlagsConfig) |
| 54 | case "fcntl_flags": |
| 55 | p = argtype.NewNumFlags(this.TypeIndex, argtype.FcntlFlagsConfig) |
| 56 | case "statx_flags": |
| 57 | p = argtype.NewNumFlags(this.TypeIndex, argtype.StatxFlagsConfig) |
| 58 | case "unlink_flags": |
| 59 | p = argtype.NewNumFlags(this.TypeIndex, argtype.UnlinkFlagsConfig) |
| 60 | case "msg_flags": |
| 61 | p = argtype.NewNumFlags(this.TypeIndex, argtype.MsgFlagsConfig) |
| 62 | case "socket_flags": |
| 63 | p = argtype.NewNumFlags(this.TypeIndex, argtype.SocketFlagsConfig) |
| 64 | case "perm_flags": |
| 65 | p = argtype.NewNumFlags(this.TypeIndex, argtype.PermissionFlagsConfig) |
| 66 | default: |
| 67 | panic("...") |
| 68 | } |
| 69 | this.TypeIndex = p.GetTypeIndex() |
| 70 | } |
| 71 | |
| 72 | func (this *PointArg) SetTypeByName(name string) { |
| 73 | this.TypeIndex = argtype.GetArgTypeByName(name).GetTypeIndex() |
no test coverage detected