Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PlacementStrategy ¶
type PlacementStrategy interface { Disable(offset int, comments []*parser.Comment, inline *parser.Comment) Finalize() error }
PlacementStrategy is an abstraction to put a comment.
func NewPlacementStrategy ¶
func NewPlacementStrategy(ptype PlacementType, filename, ruleID string) (PlacementStrategy, error)
NewPlacementStrategy creates a strategy object.
type PlacementType ¶
type PlacementType int
PlacementType is a selection of the placement strategies.
const ( // Noop does nothing Noop PlacementType = iota // ThisThenNext puts inline comments. ThisThenNext // Next puts newline comments. Next )
Click to show internal directories.
Click to hide internal directories.