Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 254992
Collapse All | Expand All

(-)earproject/org/eclipse/jst/j2ee/componentcore/util/EARVirtualComponent.java (-1 / +2 lines)
Lines 152-158 Link Here
152
			for (int i = 0; i < members.length; i++) {
152
			for (int i = 0; i < members.length; i++) {
153
				if (IVirtualResource.FILE == members[i].getType()) {
153
				if (IVirtualResource.FILE == members[i].getType()) {
154
					if(folder.isDynamicComponent((IVirtualFile)members[i])){
154
					if(folder.isDynamicComponent((IVirtualFile)members[i])){
155
						String archiveName = members[i].getRuntimePath().toString().substring(1);
155
						String archiveName = members[i].getRuntimePath().lastSegment();
156
						boolean shouldInclude = true;
156
						boolean shouldInclude = true;
157
						for (int j = 0; j < hardReferences.size() && shouldInclude; j++) {
157
						for (int j = 0; j < hardReferences.size() && shouldInclude; j++) {
158
							String tempArchiveName = ((IVirtualReference) hardReferences.get(j)).getArchiveName();
158
							String tempArchiveName = ((IVirtualReference) hardReferences.get(j)).getArchiveName();
Lines 165-170 Link Here
165
							IVirtualComponent dynamicComponent = ComponentCore.createArchiveComponent(earComponent.getProject(), VirtualArchiveComponent.LIBARCHIVETYPE + iResource.getFullPath().toString());
165
							IVirtualComponent dynamicComponent = ComponentCore.createArchiveComponent(earComponent.getProject(), VirtualArchiveComponent.LIBARCHIVETYPE + iResource.getFullPath().toString());
166
							IVirtualReference dynamicRef = ComponentCore.createReference(earComponent, dynamicComponent);
166
							IVirtualReference dynamicRef = ComponentCore.createReference(earComponent, dynamicComponent);
167
							dynamicRef.setArchiveName(archiveName);
167
							dynamicRef.setArchiveName(archiveName);
168
							dynamicRef.setRuntimePath(members[i].getRuntimePath().removeLastSegments(1));
168
							if (null == dynamicReferences) {
169
							if (null == dynamicReferences) {
169
								dynamicReferences = new ArrayList();
170
								dynamicReferences = new ArrayList();
170
							}
171
							}

Return to bug 254992