Download

Online

Gallery

Blog

  Index  | Recent Threads  | List Attachments  | Search
 Welcome Guest  |  Register  |  Login
Login Name  Password
 

Sweet Home 3D Forum



No member browsing this thread
Thread Status: Active
Total posts in this thread: 34
Posts: 34   Pages: 4   [ Previous Page | 1 2 3 4 ]
[ Jump to Last Post ]
Post new Thread
Author
Previous Thread This topic has been viewed 34811 times and has 33 replies Next Thread
son87a
Newbie




Joined: Oct 28, 2021
Post Count: 11
Status: Offline
Reply to this Post  Reply with Quote 
Re: Sweet Home 3D JS Online

I tried edit code after google. Wrap try in {}
Its working but I don't know write in finally statement.
Sorry, I'm working with PHP, and don't know Java.
Can you fix that ?

try {InputStream input = new FileInputStream(homeFile);
ByteArrayOutputStream output = new ByteArrayOutputStream();
byte[] buffer = new byte[8096];
int size;
while ((size = input.read(buffer)) != -1) {
output.write(buffer, 0, size);
}
homeFileContent = output.toByteArray();
}
finally{
// write something here ?
}



try {OutputStream servletOut = response.getOutputStream();
servletOut.write(homeFileContent);
}
finally{
// write something here ?
}

[Oct 29, 2021, 12:49:44 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Puybaret
Expert
Member's Avatar

France
Joined: Nov 7, 2005
Post Count: 7988
Status: Offline
Reply to this Post  Reply with Quote 
Re: Sweet Home 3D JS Online

You don't have to write anything in finally blocks (note that they don't even exist in the released version of readHome.jsp). I guess you should learn Java before going further...
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D developer
[Oct 29, 2021, 2:12:31 PM] Show Printable Version of Post    View Member Profile    Send Private Message    Hidden to Guest [Link] Report threatening or abusive post: please login first  Go to top 
son87a
Newbie




Joined: Oct 28, 2021
Post Count: 11
Status: Offline
Reply to this Post  Reply with Quote 
Re: Sweet Home 3D JS Online

Thank you for your time !
[Oct 30, 2021, 2:55:30 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Puybaret
Expert
Member's Avatar

France
Joined: Nov 7, 2005
Post Count: 7988
Status: Offline
Reply to this Post  Reply with Quote 
Re: Sweet Home 3D JS Online

A new version of Sweet Home 3D JS Online was released last week-end with many new features. See this blog post for more information.
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D developer
[Nov 15, 2021, 8:24:11 PM] Show Printable Version of Post    View Member Profile    Send Private Message    Hidden to Guest [Link] Report threatening or abusive post: please login first  Go to top 
Posts: 34   Pages: 4   [ Previous Page | 1 2 3 4 ]
[ Jump to Last Post ]
Show Printable Version of Thread  Post new Thread

    Get Sweet Home 3D at SourceForge.net. Fast, secure and Free Open Source software downloads
   
© Copyright 2006-2022 eTeks - All rights reserved