Updated javadoc to mention runSafely in addition to the manual locking pattern

Change-Id: Ia0ddf6149641b8dc609c5c6e53ad569c5bc9c555