Page History
...
padding | 0px |
---|---|
width | 80px |
...
Table Row (tr) | |||||
---|---|---|---|---|---|
| |||||
|
...
Table Cell (td) |
---|
byte[] |
...
Divcache | ||
---|---|---|
| DO NOT EDIT THE CONTENT OF THIS PAGE DIRECTLY (EXCEPT INSIDE THE DIV BELOW WITH ID=DESCRIPTION), UNLESS YOU KNOW WHAT YOU'RE DOING.
...
id | description |
---|
...
| |||||||||||||
...
Table Cell (td) |
---|
String |
...
...
padding | 0px |
---|---|
width | 80px |
...
...
...
Table Cell (td) |
---|
String |
...
...
Table Head (th) | ||
---|---|---|
| ||
Method Summary |
...
Table Cell (td) |
---|
UUID |
...
...
id | property |
---|---|
class | servoy sDetail |
...
padding | 0px |
---|---|
width | 100% |
Table Row (tr) | |||||
---|---|---|---|---|---|
| |||||
|
...
id | bytes |
---|
Table Row (tr) | ||
---|---|---|
| ||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
Table Row (tr) | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
|
...
class | lastDetailRow |
---|
...
id | mimeType |
---|
Table Row (tr) | ||
---|---|---|
| ||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
Table Row (tr) | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
|
...
class | lastDetailRow |
---|
...
id | function |
---|---|
class | servoy sDetail |
...
padding | 0px |
---|---|
width | 100% |
Table Row (tr) | |||||
---|---|---|---|---|---|
| |||||
|
...
id | getName |
---|
Table Row (tr) | ||
---|---|---|
| ||
|
Table Row (tr) | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
...
id | ret |
---|
...
class | sIndent |
---|
...
bytesA byte array holding the content of the Media object. Returns Supported Clients Sample mimeTypeThe MIME type of the Media object.
Some examples are: 'image/jpg', 'image/png', etc. Returns Supported Clients Sample getAsString()Returns this media's bytes a a String converting it with the UTF-8 Charset.
Returns null if it couldn't convert it or the bytes where null. Returns Supported Clients Sample getName()The name of the Media object. Returns |
...
id | sam |
---|
...
class | lastDetailRow |
---|
...
id | getUUID |
---|
Table Row (tr) | ||
---|---|---|
| ||
|
Table Row (tr) | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
Table Row (tr) | |||||||
---|---|---|---|---|---|---|---|
| |||||||
|
Table Row (tr) | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
|
...
class | lastDetailRow |
---|
...
Supported Clients Sample |
...
class | sIndent |
---|
...
Code Block | ||
---|---|---|
| ||
var ballBytes = plugins.file.readFile('d:/ball.jpg');
var mapBytes = plugins.file.readFile('d:/map.png');
var ballImage = solutionModel.newMedia('ball.jpg', ballBytes);
application.output('original image name: ' + ballImage.getName());
ballImage.bytes = mapBytes;
ballImage.mimeType = 'image/png';
application.output('image name after change: ' + ballImage.getName()); // The name remains unchanged. Only the content (bytes) are changed.
application.output('image mime type: ' + ballImage.mimeType);
application.output('image size: ' + ballImage.bytes.length); |
getUUID()Returns the UUID of this media Returns Supported Clients Sample setAsString(string)Sets the bytes of this media to the give String that is converted to bytes using the UTF-8 Charset. Parameters Supported Clients Sample |
Overview
Content Tools
Activity