A few weeks earlier I fixed a bug that the whole class was synchronized. I just removed it. A few methods however should have been synchronized instead. I've done that now.

This commit is contained in:
edwin%woudt.nl 1999-03-04 22:31:34 +00:00
Родитель 60c685ff51
Коммит 1f37845190
1 изменённых файлов: 5 добавлений и 5 удалений

Просмотреть файл

@ -67,7 +67,7 @@ public class StoreFactory {
fSession.setDebug(true);
}
public static StoreFactory Instance() {
public synchronized static StoreFactory Instance() {
if (fInstance == null) {
fInstance = new StoreFactory();
}
@ -78,7 +78,7 @@ public class StoreFactory {
return fSession;
}
public ViewedStore[] getStores() {
public synchronized ViewedStore[] getStores() {
if (fStores == null) {
updateStores();
}
@ -86,7 +86,7 @@ public class StoreFactory {
return fStores;
}
ViewedStore createStore(String storename) {
synchronized ViewedStore createStore(String storename) {
ResourceBundle labels = ResourceBundle.getBundle("grendel.ui.Labels");
URLName urlName = null;
@ -163,7 +163,7 @@ public class StoreFactory {
return null;
}
void updateStores() {
synchronized void updateStores() {
if (fSession == null) {
getSession();
}
@ -200,7 +200,7 @@ public class StoreFactory {
resVector.copyInto(fStores);
}
public void refreshStores() {
public synchronized void refreshStores() {
updateStores();
Object[] listeners = fListeners.getListenerList();