class SoundMessageContentBuilder extends MediaMessageContentBuilder {
    private int duration;
    public static SoundMessageContentBuilder newBuilder(int duration) {
        SoundMessageContentBuilder builder = new SoundMessageContentBuilder();
        builder.duration = duration;
        return builder;
    }
    @Override
    public MessagePayload build() {<FILL_FUNCTION_BODY>}
}

        MessagePayload payload = encodeBase();
        payload.setType(ProtoConstants.ContentType.Voice);
        payload.setMediaType(ProtoConstants.MessageMediaType.VOICE);
        payload.setPersistFlag(ProtoConstants.PersistFlag.Persist_And_Count);
        JSONObject jsonObject = new JSONObject();
        jsonObject.put("duration", duration);
        payload.setContent(jsonObject.toJSONString());
        return payload;
    
<methods>public non-sealed void <init>() ,public cn.wildfirechat.messagecontentbuilder.MediaMessageContentBuilder remoteMediaUrl(java.lang.String) <variables>private java.lang.String remoteMediaUrl