public CodeUnitIterator getCodeUnitIterator(String property, AddressSetView addrSetView,
			boolean forward) {

		if (addrSetView == null) {
			addrSetView = program.getMemory();
		}
		else if (addrSetView.isEmpty()) {
			return CodeUnitIterator.EMPTY_ITERATOR;
		}

		if (property.equals(CodeUnit.COMMENT_PROPERTY)) {
			try {
				AddressKeyIterator iter = commentAdapter.getKeys(addrSetView, forward);
				return new CodeUnitKeyIterator(this, iter, forward);
			}
			catch (IOException e) {
				program.dbError(e);
			}
		}
		if (property.equals(CodeUnit.INSTRUCTION_PROPERTY)) {
			try {
				AddressKeyIterator iter = instAdapter.getKeys(addrSetView, forward);
				return new CodeUnitKeyIterator(this, iter, forward);
			}
			catch (IOException e) {
				program.dbError(e);
			}
		}
		if (property.equals(CodeUnit.DEFINED_DATA_PROPERTY)) {
			try {
				AddressKeyIterator iter = dataAdapter.getKeys(addrSetView, forward);
				return new CodeUnitKeyIterator(this, iter, forward);
			}
			catch (IOException e) {
				program.dbError(e);
			}
		}
		// Possibly a user-defined property.
		PropertyMapDB<?> pm = (PropertyMapDB<?>) propertyMapMgr.getPropertyMap(property);
		if (pm != null) {
			try {
				AddressKeyIterator iter = pm.getAddressKeyIterator(addrSetView, forward);
				return new CodeUnitKeyIterator(this, iter, forward);
			}
			catch (IOException e) {
				program.dbError(e);
			}
		}
		return new EmptyCodeUnitIterator();
	}
Get an iterator that contains the code units which have the specified property type defined. 
Only code units starting within the address set specified will be returned by the iterator.
If the address set is null then check the entire program.
<br>
Standard property types are defined in the CodeUnit class.  The property types are:
         <ul>
             <li>REFERENCE_PROPERTY</li>
             <li>INSTRUCTION_PROPERTY</li>
             <li>DEFINED_DATA_PROPERTY</li>
         </ul>
Property types can also be user defined.

@param property the name of the property type, or this can be user defined.
@param addrSetView the address set to iterate, or null to iterate over the entire program
@param forward true means the iterator is in the forward direction
@return a CodeUnitIterator that returns all code units from the indicated address set that 
have the specified property type defined.
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/code/CodeManager.java