Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.7DR#3
-
Component/s: ICE-Components
-
Labels:None
-
Environment:normal JSF deployment
-
Workaround Exists:Yes
-
Workaround Description:Manualy copy InputFile properties into a new object.
Description
I was just reviewing the component showcase inputFile example and finally took the time to look into an issue that has been bugging me fore some time.
When using inputFile component a user binds an method to it to which is called when the file is successfully uploaded. The user then can get the InputFile object that was uploaded.
public void uploadFile(ActionEvent event) {
InputFile inputFile = (InputFile) event.getSource();
.....
}
The problem I have is that InputFile is reset right after the my uploadFile method is called leaving me with a useless object. The only work around is to copy the needed properties in to a new object or say good bye.
Here's what I think would be acceptable solutions:
- have Input file implement a deep clone method
- better yet have the component create a new instance of InputFile so that I can decide on how they should be reset/disposed.
When using inputFile component a user binds an method to it to which is called when the file is successfully uploaded. The user then can get the InputFile object that was uploaded.
public void uploadFile(ActionEvent event) {
InputFile inputFile = (InputFile) event.getSource();
.....
}
The problem I have is that InputFile is reset right after the my uploadFile method is called leaving me with a useless object. The only work around is to copy the needed properties in to a new object or say good bye.
Here's what I think would be acceptable solutions:
- have Input file implement a deep clone method
- better yet have the component create a new instance of InputFile so that I can decide on how they should be reset/disposed.
Activity
Field | Original Value | New Value |
---|---|---|
Assignee | Ken Fyten [ ken.fyten ] |
Assignee | Ken Fyten [ ken.fyten ] | Mark Collette [ mark.collette ] |
Fix Version/s | 1.7 [ 10080 ] | |
Assignee Priority | P2 |
Fix Version/s | 1.7Beta1 [ 10121 ] | |
Fix Version/s | 1.7 [ 10080 ] |
Fix Version/s | 1.7 [ 10080 ] | |
Fix Version/s | 1.7Beta1 [ 10121 ] |
Assignee Priority | P2 | P3 |
Assignee Priority | P3 | P1 |
Comment | [ Ignore the last comment, it was for ICE-2630. ] |
Security | Private [ 10001 ] |
Repository | Revision | Date | User | Message |
ICEsoft Public SVN Repository | #15932 | Wed Mar 05 11:57:09 MST 2008 | mark.collette | |
Files Changed | ||||
![]() ![]() |
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Fix Version/s | 1.7RC1 [ 10123 ] | |
Fix Version/s | 1.7 [ 10080 ] |
Fix Version/s | 1.7 [ 10080 ] |
Status | Resolved [ 5 ] | Closed [ 6 ] |
Assignee Priority | P1 | |
Assignee | Mark Collette [ mark.collette ] |
Can you get Adnan to take a look.