||Software-defined networking (SDN) and network functions (NF) are two essential technologies that need to work to- gether to achieve the goal of highly programmable network- ing for software defined coalition (SDC). Unified SDN pro- gramming, which integrates states of network functions into SDN control plane programming, brings these two technolo- gies together. In this paper, we conduct the first systematic study of unified SDN programming. We first show that inte- grating asynchronous, continuously changing states of net- work functions into SDN can introduce basic complexities. We then present Trident, a novel, unified SDN program- ming framework that introduces programming primitives including stream attributes, route algebra and live variables to remove these complexities. We demonstrate the expres- siveness of Trident using realistic use cases and conduct an extensive evaluation of its efficiency.