MCPcopy Create free account
hub / github.com/Proryanator/encoder-benchmark / validate

Method validate

permutor-cli/src/permutor_cli.rs:55–77  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

53
54impl PermutorCli {
55 pub fn validate(&mut self) {
56 standard_cli_check(
57 self.list_supported_encoders,
58 &self.encoder,
59 &self.source_file,
60 &self.files_directory,
61 false,
62 );
63
64 if self.source_file.is_empty() {
65 println!("Error: No source file was provided to run on, please specify an input file");
66 error_with_ack(false);
67 }
68
69 if self.max_bitrate_permutation.is_none() {
70 self.max_bitrate_permutation = Option::from(self.bitrate);
71 }
72
73 if self.source_file.is_empty() && !self.files_directory.is_empty() {
74 // internally map the source_file and source_files_directory together
75 self.source_file = format!("{}/{}", self.files_directory, self.source_file);
76 }
77 }
78
79 pub fn has_special_options(&self) -> bool {
80 return self.check_quality

Callers 1

mainFunction · 0.45

Calls 3

standard_cli_checkFunction · 0.85
error_with_ackFunction · 0.85
is_emptyMethod · 0.80

Tested by

no test coverage detected