class ActionRawUnitCommand implements Sc2ApiSerializable<Raw.ActionRawUnitCommand>, GeneralizableAbility<ActionRawUnitCommand> {

    @Override
    public Raw.ActionRawUnitCommand toSc2Api() {
        Raw.ActionRawUnitCommand.Builder aSc2ApiUnitCommand = Raw.ActionRawUnitCommand.newBuilder()
                .setAbilityId(ability.toSc2Api())
                .addAllUnitTags(unitTags.stream().map(Tag::toSc2Api).collect(toSet()))
                .setQueueCommand(queued);

        getTargetedUnitTag().map(Tag::toSc2Api).ifPresent(aSc2ApiUnitCommand::setTargetUnitTag);
        getTargetedWorldSpacePosition().map(Point2d::toSc2Api).ifPresent(aSc2ApiUnitCommand::setTargetWorldSpacePos);

        return aSc2ApiUnitCommand.build();
    }

    private  ActionRawUnitCommand(Builder builder);
    private  ActionRawUnitCommand(Raw.ActionRawUnitCommand sc2ApiActionRawUnitCommand);

}