code: public Pattern getPattern()
  	{
  		if(pattern == null) {
  			pattern = constructPattern();
  			if (this instanceof SIFMiner && idFetcher != null && idMap != null) {
  				pattern.add(new HasAnID(idFetcher, idMap), ((SIFMiner) this).getSourceLabel());
  				pattern.add(new HasAnID(idFetcher, idMap), ((SIFMiner) this).getTargetLabel());
  			}
  			pattern.optimizeConstraintOrder();
  		}
  		return pattern;
  	}
docs: Gets the pattern, constructs if null.
  @return pattern