StringIndented returns the same thing as String(), but applies the indent at every 10th bit, and twice at every 50th bit.
(indent string)
| 305 | // StringIndented returns the same thing as String(), but applies the indent |
| 306 | // at every 10th bit, and twice at every 50th bit. |
| 307 | func (bA *BitArray) StringIndented(indent string) string { |
| 308 | if bA == nil { |
| 309 | return "nil-BitArray" |
| 310 | } |
| 311 | bA.mtx.Lock() |
| 312 | defer bA.mtx.Unlock() |
| 313 | return bA.stringIndented(indent) |
| 314 | } |
| 315 | |
| 316 | func (bA *BitArray) stringIndented(indent string) string { |
| 317 | lines := []string{} |
no test coverage detected