Extend Batch interface with Close, Check, and MoveFile methods for enhanced functionality

This commit is contained in:
2026-04-26 15:26:15 +05:00
parent c4bd51d9bc
commit b36479c0ae
+12
View File
@@ -23,9 +23,21 @@ type BatchBuilder interface {
// Build returns a batch of commands. // Build returns a batch of commands.
Build() Batch Build() Batch
// Close closes the batch.
Close() error
} }
type Batch interface { type Batch interface {
// Args returns the arguments of the batch. // Args returns the arguments of the batch.
Args() []string Args() []string
// Check checks the validity of the batch.
Check(command Command) error
// Close closes the batch.
Close() error
// MoveFile moves the batch file to the specified path.
MoveFile(path string) error
} }