...
Once imported, the Solutions can be tested with Servoy 6. Servoy 6 introduces a few minor behavior changes, some of which could potentially break existing code. It should be investigated if the upgraded solutions are affected by these changes. The behavior changes are listed and discussed in the paragraph #Behavior Behavior Changes.
After taking care of the behavior changes, there are 2 tasks left:
...
As of Servoy 6, Problem markers will be generated on the JavaScript code that accesses deprecated API. The API will still function as before, the Problem markers are just an indication that the used API is marked as "Should not use anymore" and that at one point in time the code ought to be rewritten to utilize the new way of doing things. The #Deprecated Deprecated API alinea below provides an overview of the API that got deprecated in Servoy 6.0 and what the replacement functionality is.
...
The majority of the deprecations in the Runtime API are related to the new windowing API and the refactored HTTP plugin.
Object | Deprecated method or property | Replacement | Comment | |
---|---|---|---|---|
controller | .getContainerName() | controller.getWindow().getName() |
| |
Button | .setBorder() | .border | Matching getters or setters added, allowing both getting and setting the value. | |
RuntimeLabel | .getParameterValue() | N/A | Never worked properly | |
Date | .setYear() | .getFullYear() | This function is deprecated in the JavaScript specification | |
Application | .getStartupArguments() | onOpen event handler of the solution | Deeplink arguments are now passed to both the onOpen event handler of the Login and Main solution. | |
| .closeForm() | JSWindow.hide() | Servoy 6 contains a complete new Windowing API. A window or dialog is now an instance of the JSWindow class to which a lot of the methods have been moved. New methods were added to the application and controller objects to interact with windows | |
| .getWindowHeight() | JSWindow.getHeight() |
| |
| .getWindowWidth() | JSWindow.getWidth() |
| |
| .getWindowX() | JSWindow.getX() |
| |
| .getWindowY() | JSWindow.getY() |
| |
| .setWindowLocation() | JSWindow.setLocation() |
| |
| .setWindowSize() | JSWindow.setSize() |
| |
| .showFormInDialog() | application.createWindow('name',JSWindow.DIALOG).show('formName') | The method application.createWindow(..) returns an object of type JSWindow, which has an Scripting API to control additional things like the title, resizability, initial bounds and whether or not to show a textToolbar | |
| .showFormInWindow() | application.createWindow('name',JSWindow.WINDOW).show('formName') |
| |
UICONSTANTS | .FULL_SCREEN | JSWindow.FULL_SCREEN |
| |
JSForm | .rowBGColorCalculation | CSS Row Styling & onRender event |
| |
JSPortal | .resizeble | .resizable | Fix typo | |
| .rowBGColorCalculation | CSS Row Styling & onRender event |
| |
JSTabPanel | .onTabChange | .onChange | <ac:structured-macro ac:name="unmigrated-wiki-markup" ac:schema-version="1" ac:macro-id="83e88aa4-9d91-4381-b578-66042284265e"><ac:plain-text-body><![CDATA[ | |
databaseManager | .getFoundSetDataProviderAsArray() | .convertToDataSet(['dataProviderId']).getColumnAsArray(1) | Duplicate functionality | ]]></ac:plain-text-body></ac:structured-macro> |
ServoyException | .INVALID_INPUT_FORMAT | N/A | never raised | |
plugins.file | .getHomeDirectory() | .getHomeFolder() | Match naming convention | |
| .getRemoteList() | .getRemoteFolderContents() | Match naming convention | |
plugins.http | .createHttpClient() | .createNewHttpClient() | The HTTP plugin was refactored to support all types of HTTP Requests and support more finegrained control over the requests. Instead of creating an HttpClient and referencing it by name, the HttpClient is now an object with it's own set of methods, for example methods to create all the different types of HttpRequests. Each XxxxRequest object has a .executeRequest() function that returns a Response object again with it's own methods. | |
| .deleteHttpClient() | N/A | No longer required | |
| .getHttpClientCookie() | .getCookie() on HttpClient object |
| |
| .getHttpClientCookies() | .getCookies() on HttpClient object |
| |
| .getLastPageCharset() | replaced by .getCharset() on Response object returned by the .executeRequest() method on any of the XxxxRequest objects created by the .createXxxRequest() methods on the HttpClient object |
| |
| .getPoster() | .createPostRequest() on HttpClient object |
| |
| .put() | .createPutRequest() on HttpClient object |
| |
| .setClientProxyUserNamePassword() | .setClientProxyCredentials() on HttpClient object |
| |
| .setHttpClientCookie() | .setCookie() on HttpClient object |
| |
plugins.window | setToolBarVisible() | .setToolBarAreaVisible() | Name now matches what the function does | |
MenuBar | .validate() | N/A | No longer required |
...
The behavior of databaseManager.addTableFilterParam() has been changed, see #Changes Changes that might break existing code
...