import com.google.gson.JsonObject;
+import java.io.UnsupportedEncodingException;
+
public interface Policy {
String getName();
JsonObject getJsonRepresentation();
+ String createPolicyPayload() throws UnsupportedEncodingException;
+
+ /**
+ * Generate the policy name.
+ *
+ * @param policyType
+ * The policy type
+ * @param serviceName
+ * The service name
+ * @param serviceVersion
+ * The service version
+ * @param resourceName
+ * The resource name
+ * @param blueprintFilename
+ * The blueprint file name
+ * @return The generated policy name
+ */
static String generatePolicyName(String policyType, String serviceName, String serviceVersion, String resourceName,
String blueprintFilename) {
StringBuilder buffer = new StringBuilder(policyType).append("_").append(serviceName).append("_v")