MCPcopy Create free account
hub / github.com/VirusTotal/vt-cli / GetAndPrintObjects

Method GetAndPrintObjects

utils/printer.go:161–163  ·  view source on GitHub ↗

GetAndPrintObjects retrieves objects from the specified endpoint and prints them. The endpoint must contain a %s placeholder that will be replaced with items from the args slice. If args contains a single "-" string, the args are read from stdin one per line. If argRe is non-nil, only args that matc

(endpoint string, r StringReader, argRe *regexp.Regexp)

Source from the content-addressed store, hash-verified

159// read from stdin one per line. If argRe is non-nil, only args that match the
160// regular expression are used and the rest are discarded.
161func (p *Printer) GetAndPrintObjects(endpoint string, r StringReader, argRe *regexp.Regexp) error {
162 return p.GetAndPrintObjectsWithFallback([]string{endpoint}, r, argRe)
163}
164
165// GetAndPrintObjectsWithFallback retrieves objects from the specified endpoints and
166// prints them. The function tries the endpoints in the order they are provided

Callers 14

NewAnalysisCmdFunction · 0.95
NewHuntingRulesetCmdFunction · 0.95
NewFileCmdFunction · 0.95
NewIOCStreamCmdFunction · 0.95
NewRetrohuntCmdFunction · 0.95
NewMonitorCmdFunction · 0.95
NewThreatProfileCmdFunction · 0.95
NewGroupCmdFunction · 0.95
NewIPCmdFunction · 0.95
NewCollectionCmdFunction · 0.95
NewURLCmdFunction · 0.95

Calls 1

Tested by

no test coverage detected