private PublicationSettings deserializePublicationSettings(final JsonObject jsonObject) {
        if (!jsonObject.has("publish"))
            return null;

        final JsonObject publish = jsonObject.get("publish").getAsJsonObject();

        final String hexAddress = publish.get("address").getAsString();
        final int publishAddress;
        UUID uuid = null;
        if (MeshParserUtils.isUuidPattern(hexAddress)) {
            uuid = UUID.fromString(MeshParserUtils.formatUuid(hexAddress));
            publishAddress = MeshAddress.generateVirtualAddress(uuid);
        } else {
            publishAddress = Integer.parseInt(hexAddress, 16);
        }

        final int ttl = publish.get("ttl").getAsByte();

        //Previous version stored the publication period as resolution and steps.
        //Now it's stored as an interval in ms
        final int publicationResolution;
        final int publicationSteps;
        if (!publish.get("period").isJsonObject()) {
            final int period = publish.get("period").getAsInt();
            if (period % 600000 == 0) {
                publicationResolution = RESOLUTION_10_M;
                publicationSteps = period / 600000;
            } else if (period % 10000 == 0) {
                publicationResolution = RESOLUTION_10_S;
                publicationSteps = period / 10000;
            } else if (period % 1000 == 0) {
                publicationResolution = RESOLUTION_1_S;
                publicationSteps = period / 1000;
            } else if (period % 100 == 0) {
                publicationResolution = RESOLUTION_100_MS;
                publicationSteps = period / 100;
            } else {
                // This is to maintain backward compatibility between older json files
                publicationResolution = period & 0x03;
                publicationSteps = period >> 6;
            }
        } else {
            final JsonObject periodJson = publish.get("period").getAsJsonObject();
            publicationSteps = periodJson.get("numberOfSteps").getAsInt();
            publicationResolution = PublicationSettings.deserializePublicationResolution(periodJson.get("resolution").getAsInt());
        }


        final int publishRetransmitCount = publish.get("retransmit").getAsJsonObject().get("count").getAsInt();
        // Here we should import the interval in to retransmit interval steps to maintain compatibility with iOS
        // as well as the internal publication api
        int publishRetransmitIntervalSteps = publish.get("retransmit").getAsJsonObject().get("interval").getAsInt();
        if (publishRetransmitIntervalSteps >= 50) {
            publishRetransmitIntervalSteps = PublicationSettings.parseRetransmitIntervalSteps(publishRetransmitIntervalSteps);
        }
        final boolean credentials = publish.get("credentials").getAsInt() == 1;

        //Set the values
        final PublicationSettings publicationSettings = new PublicationSettings();
        publicationSettings.setPublishAddress(publishAddress);
        publicationSettings.setLabelUUID(uuid);
        publicationSettings.setPublishTtl(ttl);
        publicationSettings.setPublicationSteps(publicationSteps);
        publicationSettings.setPublicationResolution(publicationResolution);
        publicationSettings.setPublishRetransmitCount(publishRetransmitCount);
        publicationSettings.setPublishRetransmitIntervalSteps(publishRetransmitIntervalSteps);
        publicationSettings.setCredentialFlag(credentials);

        return publicationSettings;
    }
Get publication settings from json

@param jsonObject json object
@return {@link PublicationSettings}
mesh/src/main/java/no/nordicsemi/android/mesh/transport/MeshModelListDeserializer.java