Java Cheat Sheet: Difference between revisions
Jump to navigation
Jump to search
imported>Scott (Created page with '__TOC__ Java programming notes and resources. = Programming Notes = {| class="wikitable" border="1" |- | Documented Yes/No|| Min Known Version || Max Know Version |} == java…') |
imported>Scott No edit summary |
||
(4 intermediate revisions by the same user not shown) | |||
Line 3: | Line 3: | ||
Java programming notes and resources. | Java programming notes and resources. | ||
= | A discussion of thread safety by TMW employee. Discusses thread safety: http://mathforum.org/kb/message.jspa?messageID=5972347&tstart=0 | ||
== Matlab == | |||
; javaObject : ''Documented'' (7.0-2010) - Invoke a Java object constructor letting MATLAB choose the thread. | |||
<pre>X = javaObject('java.awt.Color', 0.1, 0, 0.7)</pre> | |||
;JavaFrame : ''Undocumented'' (7.0-2010) - Get underlying Java Frame from figure. | |||
<pre>get(hFig,'JavaFrame')</pre> | |||
;javacomponent : ''Undocumented'' (7.0-2010) - Create a Java Swing Component and put it in a figure. | |||
<pre> | |||
f = figure; | |||
b = javacomponent({'javax.swing.JButton','Hello'}, [], f, {'ActionPerformed','disp Hi'}); | |||
</pre> | |||
<pre> | |||
== | == Java == | ||
;java.lang.System.getProperties() : Get/Set java system properties. | |||
<pre> | |||
p = java.lang.System.getProperties(); | |||
p.setProperty('derby.stream.error.file', fullfile(evridir,'derby.log')); | |||
</pre> | |||
== Links == | |||
[http://undocumentedmatlab.com/ Undocumented Matlab] | |||
Latest revision as of 11:17, 17 January 2013
Java programming notes and resources.
A discussion of thread safety by TMW employee. Discusses thread safety: http://mathforum.org/kb/message.jspa?messageID=5972347&tstart=0
Matlab
- javaObject
- Documented (7.0-2010) - Invoke a Java object constructor letting MATLAB choose the thread.
X = javaObject('java.awt.Color', 0.1, 0, 0.7)
- JavaFrame
- Undocumented (7.0-2010) - Get underlying Java Frame from figure.
get(hFig,'JavaFrame')
- javacomponent
- Undocumented (7.0-2010) - Create a Java Swing Component and put it in a figure.
f = figure; b = javacomponent({'javax.swing.JButton','Hello'}, [], f, {'ActionPerformed','disp Hi'});
Java
- java.lang.System.getProperties()
- Get/Set java system properties.
p = java.lang.System.getProperties(); p.setProperty('derby.stream.error.file', fullfile(evridir,'derby.log'));