Преглед на файлове

Declare annotation: guard added for model building... (perf improvement!)

tags/V1_5_0M2
aclement преди 19 години
родител
ревизия
08fdf0bb14
променени са 1 файла, в които са добавени 17 реда и са изтрити 0 реда
  1. 17
    0
      asm/src/org/aspectj/asm/AsmManager.java

+ 17
- 0
asm/src/org/aspectj/asm/AsmManager.java Целия файл

@@ -8,6 +8,7 @@
*
* Contributors:
* Mik Kersten initial implementation
* Andy Clement incremental support and switch on/off state
* ******************************************************************/


@@ -37,6 +38,7 @@ public class AsmManager {
protected IHierarchy hierarchy;
private List structureListeners = new ArrayList();
private IRelationshipMap mapper;
private static boolean creatingModel = false;

public static boolean attemptIncrementalModelRepairs = false;
@@ -780,6 +782,21 @@ public class AsmManager {
AsmManager.getDefault().getRelationshipMap());
}
}

/**
* Set to indicate whether we are currently building a structure model, should
* be set up front.
*/
public static void setCreatingModel(boolean b) {
creatingModel = b;
}
/**
* returns true if we are currently generating a structure model, enables
* guarding of expensive operations on an empty/null model.
*/
public static boolean isCreatingModel() { return creatingModel;}
}


Loading…
Отказ
Запис