public static Uuid getDefaultInstance(String defaultValue) { return new Uuid(defaultValue); }
public static Uuid getDefaultInstance(String defaultValue) { return new Uuid(defaultValue); }
@Override protected Object doExecute() throws Exception { UUID uuid = UUID.randomUUID(); List<Subjects> subjects = createSubjects(); List<Actions> intentActions = createActions(); Intent intent = new IntentBuilder(). setId(new Uuid(uuid.toString())) .setSubjects(subjects) .setActions(intentActions) .build(); if (provider.addIntent(intent)) { return String.format("Intent created (id: %s)", uuid.toString()); } else { return "Error creating new intent"; } }