Create a new inbox that is prefix aware.
()
| 4727 | |
| 4728 | // Create a new inbox that is prefix aware. |
| 4729 | func (nc *Conn) NewInbox() string { |
| 4730 | if nc.Opts.InboxPrefix == _EMPTY_ { |
| 4731 | return NewInbox() |
| 4732 | } |
| 4733 | |
| 4734 | var sb strings.Builder |
| 4735 | sb.WriteString(nc.Opts.InboxPrefix) |
| 4736 | sb.WriteByte('.') |
| 4737 | sb.WriteString(nuid.Next()) |
| 4738 | return sb.String() |
| 4739 | } |
| 4740 | |
| 4741 | // Function to init new response structures. |
| 4742 | func (nc *Conn) initNewResp() { |