Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bonita
bonita-studio
Commits
15be455c
Commit
15be455c
authored
Sep 24, 2015
by
Romain Bioteau
Committed by
Romain Bioteau
Sep 25, 2015
Browse files
BS-14324
Export related resources when exporting a repository (not only based on canBeExported)
parent
96e6cac2
Changes
2
Hide whitespace changes
Inline
Side-by-side
bundles/plugins/org.bonitasoft.studio.common.repository/src/org/bonitasoft/studio/common/repository/Repository.java
View file @
15be455c
...
...
@@ -502,6 +502,7 @@ public class Repository implements IRepository, IJavaContainer {
final
Set
<
IResource
>
allResources
=
new
HashSet
<
IResource
>();
for
(
final
IRepositoryStore
<?>
store
:
getAllExportableStores
())
{
allResources
.
add
(
store
.
getResource
());
allResources
.
addAll
(
allRelatedResources
(
store
));
}
operation
.
setResources
(
allResources
);
final
IStatus
status
=
operation
.
run
(
NULL_PROGRESS_MONITOR
);
...
...
@@ -510,6 +511,16 @@ public class Repository implements IRepository, IJavaContainer {
}
}
private
List
<
IResource
>
allRelatedResources
(
final
IRepositoryStore
<?>
store
)
{
final
List
<
IResource
>
relatedResources
=
new
ArrayList
<
IResource
>();
for
(
final
IRepositoryFileStore
fs
:
store
.
getChildren
())
{
for
(
final
IRepositoryFileStore
related
:
fs
.
getRelatedFileStore
())
{
relatedResources
.
add
(
related
.
getResource
());
}
}
return
relatedResources
;
}
protected
void
logErrorStatus
(
final
IStatus
status
)
{
final
StringBuilder
sb
=
new
StringBuilder
();
if
(
status
.
isMultiStatus
())
{
...
...
bundles/plugins/org.bonitasoft.studio.diagram.custom/src/org/bonitasoft/studio/diagram/custom/repository/ProcessConfigurationRepositoryStore.java
View file @
15be455c
/**
* Copyright (C) 2012
-2015
Bonita
s
oft S.A.
* Bonita
s
oft, 3
2
rue Gustave Eiffel - 38000 Grenoble
* Copyright (C) 2012 Bonita
S
oft S.A.
* Bonita
S
oft, 3
1
rue Gustave Eiffel - 38000 Grenoble
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2.0 of the License, or
...
...
@@ -13,7 +13,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package
org.bonitasoft.studio.diagram.custom.repository
;
import
java.io.File
;
import
java.io.File
;
import
java.io.FileInputStream
;
import
java.io.FileNotFoundException
;
import
java.io.IOException
;
...
...
@@ -51,7 +52,6 @@ import org.eclipse.emf.edapt.spi.history.Release;
import
org.eclipse.emf.edit.provider.ComposedAdapterFactory
;
import
org.eclipse.swt.graphics.Image
;
/**
* @author Romain Bioteau
*/
...
...
@@ -76,7 +76,7 @@ public class ProcessConfigurationRepositoryStore extends AbstractEMFRepositorySt
@Override
public
boolean
canBeExported
()
{
return
tru
e
;
return
fals
e
;
}
@Override
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment