All existing railroad corporations within this state, and such as may be hereafter chartered or formed, shall, respectively, have and possess all the powers and privileges contained in this chapter; and they shall be subject to all the duties, liabilities and provisions not inconsistent with the provisions of their charter herein contained.