public List<Level> getLevels() {
        return levels;
    }
Gets all of the hierarchical levels of the topic.

@return Returns the topic levels.
smithy-mqtt-traits/src/main/java/software/amazon/smithy/mqtt/traits/Topic.java