void (int offset, String text) { for (Marker marker : myMarkers) { if (offset < marker.getStartOffset()) { marker.myStartOffset += text.length(); } else if (offset <= marker.getEndOffset()) { marker.myEndOffset += text.length(); } } }