<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def put(self, entity):
 """Adds an entity to be committed. Ensures the transaction is not marked readonly. Please see documentation at :meth:`~google.cloud.datastore.batch.Batch.put` :type entity: :class:`~google.cloud.datastore.entity.Entity` :param entity: the entity to be saved. :raises: :class:`RuntimeError` if the transaction is marked ReadOnly """

        if self._options.HasField("read_only"):
            raise RuntimeError("Transaction is read only")
        else:
            super(Transaction, self).put(entity)