Precise spectra of 3C 279 in the 0.5-70 keV range , obtained during two epochs of Swift and NuSTAR observations , are analyzed using a near-equipartition model . We apply a one-zone leptonic model with a three-parameter log-parabola electron energy distribution ( EED ) to fit the Swift and NuSTAR X-ray data , as well as simultaneous optical and Fermi -LAT \gamma -ray data . The Markov Chain Monte Carlo ( MCMC ) technique is used to search the high-dimensional parameter space and evaluate the uncertainties on model parameters . We show that the two spectra can be successfully fit in near-equipartition conditions , defined by the ratio of the energy density of relativistic electrons to magnetic field \zeta _ { e } being close to unity . In both spectra , the observed X-rays are dominated by synchrotron-self Compton photons , and the observed \gamma rays are dominated by Compton scattering of external infrared photons from a surrounding dusty torus . Model parameters are well constrained . From the low state to the high state , both the curvature of the log-parabola width parameter and the synchrotron peak frequency significantly increase . The derived magnetic fields in the two states are nearly identical ( \sim 1 G ) , but the Doppler factor in the high state is larger than that in the low state ( \sim 28 versus \sim 18 ) . We derive that the gamma-ray emission site takes place outside the broad-line region , at \gtrsim 0.1 pc from the black hole , but within the dusty torus . Implications for 3C 279 as a source of high-energy cosmic-rays are discussed .