public static ISecret CreateSecret(string type, string value) { ISecret result; switch (type) { case PlainTextSecret.Name: result = new PlainTextSecret(value); break; case BCryptSecret.Name: result = new BCryptSecret(value); break; default: result = null; break; } return result; }
public static ISecret CreateSecret(string type, string value) { ISecret result; switch (type) { case PlainTextSecret.Name: result = new PlainTextSecret(value); break; case BCryptSecret.Name: result = new BCryptSecret(value); break; default: result = null; break; } return(result); }