maybe you could use an enum for primary/secondary ("enum class" please)