<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Julius Beckmann</title>
	<atom:link href="http://juliusbeckmann.de/blog/feed" rel="self" type="application/rss+xml" />
	<link>http://juliusbeckmann.de/blog</link>
	<description>Ich bin nicht verrückt, nur technisch begabt ...</description>
	<lastBuildDate>Thu, 15 Dec 2011 14:35:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Android: Move ringtones from SD-Card to internal memory</title>
		<link>http://juliusbeckmann.de/blog/android-move-ringtones-from-sd-card-to-internal-memory.html</link>
		<comments>http://juliusbeckmann.de/blog/android-move-ringtones-from-sd-card-to-internal-memory.html#comments</comments>
		<pubDate>Thu, 15 Dec 2011 14:35:13 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Bash]]></category>
		<category><![CDATA[Memory]]></category>
		<category><![CDATA[Ringtone]]></category>
		<category><![CDATA[Root]]></category>
		<category><![CDATA[SD-Card]]></category>
		<category><![CDATA[Terminal]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=900</guid>
		<description><![CDATA[I have a Motorola Milestone and keep it inside the Desk-Dockingstation all day long. While it is in there, the phone cant use the ringtones saved on the sd-card, because the sd-card is shared over USB. I simply moved my ringtone to the internal ringtone memory. You need root access and a terminal to put [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full wp-image-896" title="android-180" src="http://juliusbeckmann.de/blog/static/android-180.png" alt="android-180" width="180" height="180" />I have a Motorola Milestone and keep it inside the Desk-Dockingstation all day long. While it is in there, the phone cant use the ringtones saved on the sd-card, because the sd-card is shared over USB. I simply moved my ringtone to the internal ringtone memory.</p>
<p><span id="more-900"></span></p>
<p>You need <strong>root access</strong> and a <strong>terminal</strong> to put in these commands:</p>
<p>WARNING:<br />
Be carefull because this could ruin your system!</p>
<div class="codesnip-container" >su -<br />
cd /<br />
mount -o remout,rw /system<br />
cp /sdcard/media/ringtones/YOURRINGTONE.mp3 /system/media/ringtones/<br />
exit</div>
<p>Afterwards restart you phone, delete the ringtone file vom sdcard and select the internal ringtone. Should be working now :)</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/android-move-ringtones-from-sd-card-to-internal-memory.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android: Install Google Mail in Cyanogen 7 and similar</title>
		<link>http://juliusbeckmann.de/blog/android-install-google-mail-in-cyanogen-7-and-similar.html</link>
		<comments>http://juliusbeckmann.de/blog/android-install-google-mail-in-cyanogen-7-and-similar.html#comments</comments>
		<pubDate>Wed, 07 Dec 2011 23:50:50 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Cyanogen]]></category>
		<category><![CDATA[GMail]]></category>
		<category><![CDATA[Google]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=894</guid>
		<description><![CDATA[How to install Google Mail (GMail) on your Cyanogen Android Phone: 1. The Google Mail app is just available in USA Market. You need the app "Market Enabler" and fake a USA Provider like Verizon or T-Mobile. 2. Search for "Google Mail" or "Gmail" in the Market, if it does show up, install it. 3. [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/android-180.png" alt="android-180" title="android-180" width="180" height="180" class="alignright size-full wp-image-896" />How to install Google Mail (GMail) on your Cyanogen Android Phone:</p>
<p>1. The Google Mail app is just available in USA Market. You need the app "Market Enabler" and fake a USA Provider like Verizon or T-Mobile.</p>
<p>2. Search for "Google Mail" or "Gmail" in the Market, if it does show up, install it.</p>
<p>3. If you cant find Google Mail in the Market, go to ww.appbrain.com and search for "Gmail". Use the QR Code + Browser to install Google Mail.</p>
<p>If you need any more Google Apps, check out this Wiki entry:<br />
<a href="http://wiki.cyanogenmod.com/index.php?title=Latest_Version/Google_Apps">http://wiki.cyanogenmod.com/index.php?title=Latest_Version/Google_Apps</a></p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/android-install-google-mail-in-cyanogen-7-and-similar.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox: Black form input fields when using a dark GTK / Gnome theme</title>
		<link>http://juliusbeckmann.de/blog/firefox-black-form-input-fields-when-using-a-dark-gtk-gnome-theme.html</link>
		<comments>http://juliusbeckmann.de/blog/firefox-black-form-input-fields-when-using-a-dark-gtk-gnome-theme.html#comments</comments>
		<pubDate>Tue, 22 Nov 2011 20:32:23 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[Allgemein]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Dark]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[Forms]]></category>
		<category><![CDATA[GTK]]></category>
		<category><![CDATA[Settings]]></category>
		<category><![CDATA[Theme]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=887</guid>
		<description><![CDATA[I recently switched to a dark Gnome2 theme and realized, that firefox did use that colors too. But also firefox used these colors for the input forms on some websites. I found out how to partially fix this. These strangely colored input field will be there when the website did not define any other colors [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/firefox.png" alt="firefox" title="firefox" width="120" height="120" class="alignright size-full wp-image-889" /></p>
<p>I recently switched to a dark Gnome2 theme and realized, that firefox did use that colors too. But also firefox used these colors for the input forms on some websites. I found out how to partially fix this.</p>
<p><span id="more-887"></span></p>
<p>These strangely colored input field will be there when the website did not define any other colors to these elements.</p>
<p>There is a way to make these fields white again with the following instructions:</p>
<p>You need to create or append this file</p>
<div class="codesnip-container" >.mozilla/firefox/YOUR_PROFILE/chrome/userContent.css</div>
<p>with this content:</p>
<div class="codesnip-container" >/**<br />
 * Default colors for HTML-Forms when using dark GTK Themes.<br />
 *<br />
 * @author Julius Beckmann kontakt@juliusbeckmann.de<br />
 */</p>
<p>button,<br />
input,<br />
input[type="radio"],<br />
input[type="checkbox"],<br />
input[type="reset"],<br />
input[type="button"],<br />
input[type="submit"],<br />
select,<br />
textarea {<br />
    -moz-appearance: none !important;<br />
    background-color: white;<br />
    color: black;<br />
}</p></div>
<p>Download: <a href="/static/firefox/userContent.css">userContent.css</a></p>
<p>It will give Firefox default values to use when a website does not set any colors for form inputs.<br />
You need to restart Firefox to activate these settings.</p>
<p>You can test it here: <a href="/static/firefox/forms.html">Test-Forms</a></p>
<p>But the check-box input fields are still black. I think because Firefox does not render these Elements on its own, but let GTK do it. I could not find any method to reset these to normal again.</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/firefox-black-form-input-fields-when-using-a-dark-gtk-gnome-theme.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP: Uncomment PHP Code</title>
		<link>http://juliusbeckmann.de/blog/php-uncomment-php-code.html</link>
		<comments>http://juliusbeckmann.de/blog/php-uncomment-php-code.html#comments</comments>
		<pubDate>Fri, 18 Nov 2011 09:33:52 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Comment]]></category>
		<category><![CDATA[Gist]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[Script]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=883</guid>
		<description><![CDATA[If you want to uncomment your PHP Code, have a look at my script: https://gist.github.com/1375986 Usage: # php uncomment /path/to/file.php The script will read the content of the file, remove the comment, and write back to the file. So the file will be CHANGED! You have been warned.]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/php-logo.jpg" alt="php-logo" title="php-logo" width="100" height="55" class="alignright size-full wp-image-855" /></p>
<p>If you want to uncomment your PHP Code, have a look at my script:</p>
<p><a href="https://gist.github.com/1375986">https://gist.github.com/1375986</a></p>
<p>Usage:</p>
<div class="codesnip-container" ># php uncomment /path/to/file.php</div>
<p>The script will read the content of the file, remove the comment, and write back to the file.<br />
So the file will be CHANGED! You have been warned.</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/php-uncomment-php-code.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP: The big php variable type casting!</title>
		<link>http://juliusbeckmann.de/blog/php-the-big-php-variable-type-casting.html</link>
		<comments>http://juliusbeckmann.de/blog/php-the-big-php-variable-type-casting.html#comments</comments>
		<pubDate>Sat, 05 Nov 2011 14:25:30 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=879</guid>
		<description><![CDATA[I wrote a small script that does every available cast in PHP on every datattype. Check it out on GistHub: https://gist.github.com/1341572 The output of the script should be the following: $ php casting.php --- Casting all in PHP available Types in every way --- Info: In PHP we have the following data types: boolean, int, [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/php-logo.jpg" alt="php-logo" title="php-logo" width="100" height="55" class="alignright size-full wp-image-855" />I wrote a small script that does every available cast in PHP on every datattype.<br />
Check it out on GistHub:<br />
<a href="https://gist.github.com/1341572">https://gist.github.com/1341572</a></p>
<p>The output of the script should be the following:</p>
<div class="codesnip-container" >$ php casting.php </p>
<p>--- Casting all in PHP available Types in every way ---</p>
<p>Info:<br />
In PHP we have the following data types: boolean, int, float, double, array, object,<br />
while float and double should be the same.<br />
There are other types that can not be created by cast, like resources.<br />
PHP is weak typed and allows to cast everything to everything.<br />
I think this is something every (good) Software Programmer working with PHP should know.<br />
Check out the results of the casts, especially to boolean, so you do not need<br />
if(strlen($s) > 0 || count($a) > 0) ... anymore.</p>
<p>PHP-Version: 5.3.5-1ubuntu7.3</p>
<p>--- casting 'null' ------------<br />
(boolean)null -> (boolean)false<br />
(int)null -> (integer)0<br />
(float)null -> (double)0<br />
(double)null -> (double)0<br />
(string)null -> (string)''<br />
(array)null -> (array)array ()<br />
(object)null -> (object)stdClass</p>
<p>--- casting '0' ------------<br />
(boolean)0 -> (boolean)false<br />
(int)0 -> (integer)0<br />
(float)0 -> (double)0<br />
(double)0 -> (double)0<br />
(string)0 -> (string)'0'<br />
(array)0 -> (array)array (0 => 0,)<br />
(object)0 -> (object)stdClass</p>
<p>--- casting '1' ------------<br />
(boolean)1 -> (boolean)true<br />
(int)1 -> (integer)1<br />
(float)1 -> (double)1<br />
(double)1 -> (double)1<br />
(string)1 -> (string)'1'<br />
(array)1 -> (array)array (0 => 1,)<br />
(object)1 -> (object)stdClass</p>
<p>--- casting '0.0' ------------<br />
(boolean)0.0 -> (boolean)false<br />
(int)0.0 -> (integer)0<br />
(float)0.0 -> (double)0<br />
(double)0.0 -> (double)0<br />
(string)0.0 -> (string)'0'<br />
(array)0.0 -> (array)array (0 => 0,)<br />
(object)0.0 -> (object)stdClass</p>
<p>--- casting '0.1' ------------<br />
(boolean)0.1 -> (boolean)true<br />
(int)0.1 -> (integer)0<br />
(float)0.1 -> (double)0.1<br />
(double)0.1 -> (double)0.1<br />
(string)0.1 -> (string)'0.1'<br />
(array)0.1 -> (array)array (0 => 0.1,)<br />
(object)0.1 -> (object)stdClass</p>
<p>--- casting '1.23' ------------<br />
(boolean)1.23 -> (boolean)true<br />
(int)1.23 -> (integer)1<br />
(float)1.23 -> (double)1.23<br />
(double)1.23 -> (double)1.23<br />
(string)1.23 -> (string)'1.23'<br />
(array)1.23 -> (array)array (0 => 1.23,)<br />
(object)1.23 -> (object)stdClass</p>
<p>--- casting 'true' ------------<br />
(boolean)true -> (boolean)true<br />
(int)true -> (integer)1<br />
(float)true -> (double)1<br />
(double)true -> (double)1<br />
(string)true -> (string)'1'<br />
(array)true -> (array)array (0 => true,)<br />
(object)true -> (object)stdClass</p>
<p>--- casting 'false' ------------<br />
(boolean)false -> (boolean)false<br />
(int)false -> (integer)0<br />
(float)false -> (double)0<br />
(double)false -> (double)0<br />
(string)false -> (string)''<br />
(array)false -> (array)array (0 => false,)<br />
(object)false -> (object)stdClass</p>
<p>--- casting '""' ------------<br />
(boolean)"" -> (boolean)false<br />
(int)"" -> (integer)0<br />
(float)"" -> (double)0<br />
(double)"" -> (double)0<br />
(string)"" -> (string)''<br />
(array)"" -> (array)array (0 => '',)<br />
(object)"" -> (object)stdClass</p>
<p>--- casting '"abc"' ------------<br />
(boolean)"abc" -> (boolean)true<br />
(int)"abc" -> (integer)0<br />
(float)"abc" -> (double)0<br />
(double)"abc" -> (double)0<br />
(string)"abc" -> (string)'abc'<br />
(array)"abc" -> (array)array (0 => 'abc',)<br />
(object)"abc" -> (object)stdClass</p>
<p>--- casting 'array()' ------------<br />
(boolean)array() -> (boolean)false<br />
(int)array() -> (integer)0<br />
(float)array() -> (double)0<br />
(double)array() -> (double)0<br />
(string)array() -> (string)'Array'<br />
(array)array() -> (array)array ()<br />
(object)array() -> (object)stdClass</p>
<p>--- casting 'array(1)' ------------<br />
(boolean)array(1) -> (boolean)true<br />
(int)array(1) -> (integer)1<br />
(float)array(1) -> (double)1<br />
(double)array(1) -> (double)1<br />
(string)array(1) -> (string)'Array'<br />
(array)array(1) -> (array)array (0 => 1,)<br />
(object)array(1) -> (object)stdClass</p>
<p>--- casting 'array(1, 2)' ------------<br />
(boolean)array(1, 2) -> (boolean)true<br />
(int)array(1, 2) -> (integer)1<br />
(float)array(1, 2) -> (double)1<br />
(double)array(1, 2) -> (double)1<br />
(string)array(1, 2) -> (string)'Array'<br />
(array)array(1, 2) -> (array)array (0 => 1,1 => 2,)<br />
(object)array(1, 2) -> (object)stdClass</p>
<p>--- casting 'fopen("php://stdout", "w")' ------------<br />
(boolean)fopen("php://stdout", "w") -> (boolean)true<br />
(int)fopen("php://stdout", "w") -> (integer)6<br />
(float)fopen("php://stdout", "w") -> (double)7<br />
(double)fopen("php://stdout", "w") -> (double)8<br />
(string)fopen("php://stdout", "w") -> (string)'Resource id #9'<br />
(array)fopen("php://stdout", "w") -> (array)array (0 => NULL,)<br />
(object)fopen("php://stdout", "w") -> (object)stdClass</p>
<p>--- casting 'new A()' ------------<br />
(boolean)new A() -> (boolean)true<br />
PHP Notice:  Object of class A could not be converted to int in casting.php(67) : eval()'d code on line 1<br />
(int)new A() -> (integer)1<br />
PHP Notice:  Object of class A could not be converted to double in casting.php(67) : eval()'d code on line 1<br />
(float)new A() -> (double)1<br />
PHP Notice:  Object of class A could not be converted to double in casting.php(67) : eval()'d code on line 1<br />
(double)new A() -> (double)1<br />
(string)new A() -> (string)'A'<br />
(array)new A() -> (array)array ()<br />
(object)new A() -> (object)A</p>
<p>--- PROBLEMS ------------<br />
Some constructs in PHP need a parameter type to work correnctly,<br />
like foreach() and many functions like implode() ....</p>
<p>foreach(array("works") as $a) {}<br />
PHP Warning:  Invalid argument supplied for foreach() in casting.php on line 78<br />
PHP Warning:  Invalid argument supplied for foreach() in casting.php on line 79<br />
PHP Warning:  Invalid argument supplied for foreach() in casting.php on line 80<br />
implode('', array("works"));<br />
PHP Warning:  implode(): Invalid arguments passed in casting.php on line 84<br />
PHP Warning:  implode(): Invalid arguments passed in casting.php on line 85<br />
PHP Warning:  implode(): Invalid arguments passed in casting.php on line 86</p></div>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/php-the-big-php-variable-type-casting.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP: Playing with stdClass</title>
		<link>http://juliusbeckmann.de/blog/php-playing-with-stdclass.html</link>
		<comments>http://juliusbeckmann.de/blog/php-playing-with-stdclass.html#comments</comments>
		<pubDate>Mon, 24 Oct 2011 16:15:38 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=875</guid>
		<description><![CDATA[I wrote some code to check what PHP included stdClass is capeable of. You can find the code at gisthub: https://gist.github.com/1309031 stdClass is really just a wrapper around a array that can be casted to a array. Good thing about it is, you can extend it with some failsave __get($key) function.]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/php-logo.jpg" alt="php-logo" title="php-logo" width="100" height="55" class="alignright size-full wp-image-855" />I wrote some code to check what PHP included stdClass is capeable of.<br />
You can find the code at gisthub:<br />
<a href="https://gist.github.com/1309031">https://gist.github.com/1309031</a></p>
<p>stdClass is really just a wrapper around a array that can be casted to a array.<br />
Good thing about it is, you can extend it with some failsave __get($key) function.</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/php-playing-with-stdclass.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP: Universal NULL Object</title>
		<link>http://juliusbeckmann.de/blog/php-universal-null-object.html</link>
		<comments>http://juliusbeckmann.de/blog/php-universal-null-object.html#comments</comments>
		<pubDate>Sat, 23 Jul 2011 15:15:17 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Gist]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=869</guid>
		<description><![CDATA[When working with interfaces you sometimes need a object as parameter. Thats why i wrote this primity universal null object that does nothing at all and does not throw any errors: &#60;?php /** * Universal NULL object. * * Will throw no error messages so can be used as universal parameter. * Does overwrite all [...]]]></description>
			<content:encoded><![CDATA[<p>When working with interfaces you sometimes need a object as parameter. Thats why i wrote this primity universal null object that does nothing at all and does not throw any errors:</p>
<div class="codesnip-container" >
<div class="php codesnip" style="font-family:monospace;"><span class="kw2">&lt;?php</span><br />
<span class="co4">/**<br />
* Universal NULL object.<br />
*<br />
* Will throw no error messages so can be used as universal parameter.<br />
* Does overwrite all available magic methods used in PHP5.3.<br />
*<br />
* @author Julius Beckmann<br />
*/</span><br />
<span class="kw2">class</span> NullObject <span class="br0">&#123;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __construct<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __destruct<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __set<span class="br0">&#40;</span><span class="re0">$name</span><span class="sy0">,</span> <span class="re0">$value</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __get<span class="br0">&#40;</span><span class="re0">$name</span><span class="br0">&#41;</span> <span class="br0">&#123;</span> <span class="kw1">return</span> <span class="kw4">null</span><span class="sy0">;</span> <span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __isset<span class="br0">&#40;</span><span class="re0">$name</span><span class="br0">&#41;</span> <span class="br0">&#123;</span> <span class="kw1">return</span> <span class="kw4">false</span><span class="sy0">;</span> <span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __unset<span class="br0">&#40;</span><span class="re0">$name</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __call<span class="br0">&#40;</span><span class="re0">$name</span><span class="sy0">,</span> <span class="re0">$args</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __toString<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span> <span class="kw1">return</span> <span class="st_h">''</span><span class="sy0">;</span> <span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __invoke<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __clone<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">static</span> <span class="kw2">function</span> __callStatic<span class="br0">&#40;</span><span class="re0">$name</span><span class="sy0">,</span> <span class="re0">$args</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><span class="br0">&#125;</span><br />
<span class="br0">&#125;</span></div>
</div>
<p>GistHub:<br />
<a href="https://gist.github.com/1101526">https://gist.github.com/1101526</a></p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/php-universal-null-object.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The project triangle</title>
		<link>http://juliusbeckmann.de/blog/the-project-triangle.html</link>
		<comments>http://juliusbeckmann.de/blog/the-project-triangle.html#comments</comments>
		<pubDate>Sun, 19 Jun 2011 10:25:22 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[Allgemein]]></category>
		<category><![CDATA[Project triangle]]></category>
		<category><![CDATA[Scrum]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=861</guid>
		<description><![CDATA[Anybody of you who worked in a (bigger) project, might have noticed that there are always problems about specific factors like time, money and quality. While getting my Scrum Master certificate, our teacher told us about something called the "project triangle". There is a wikipedia article about the project triangle. I created my own grafic [...]]]></description>
			<content:encoded><![CDATA[<p>Anybody of you who worked in a (bigger) project, might have noticed that there are always problems about specific factors like time, money and quality.<br />
While getting my Scrum Master certificate, our teacher told us about something called the "project triangle".<br />
<span id="more-861"></span><br />
There is a wikipedia article about the <a href="http://en.wikipedia.org/wiki/Project_triangle">project triangle</a>.</p>
<p>I created my own grafic about the triangle:<br />
<img src="http://juliusbeckmann.de/blog/static/time-scope-cost-triangle.png" alt="time-scope-cost-triangle" title="time-scope-cost-triangle" width="494" height="492" class="alignnone size-full wp-image-862" /><br />
Let me explain why i choose these 3 factors:</p>
<h2>Time</h2>
<p>In any project, time mostly means that there is a deadline that should not be broken. If there is not much time at all or it gets reduced, it means there is less effort for the result which leads to less quality.</p>
<h2>Cost</h2>
<p>The customers who pays for your work, always wants to pay less as possible. But reducing cost means reducing manpower and ignoring better solutions. That also leads to less quality.</p>
<h2>Scope</h2>
<p>Reducing scope of the project. Doing less as you should or doing it in a sloppy way. As long as the customer does not notice, there is no real problem, till the moment when something is broken or needs refactoring.</p>
<h2>Quality</h2>
<p>Quality = Time * Scope * Cost. If you reduce any of the 3 factors, quality will decrease. In the end, quality is what the customers pay for. Nobody would by a car that will break down in the first turn.</p>
<h2>"Pick 2"</h2>
<p>Some explanations about this concept say, you can always just pick 2 of the factors to concentrate. I do not agree with that because it makes the whole problem way too easy. There are ways to solve this so the best possible product is created. I count agile development like scrum and kanban to this.</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/the-project-triangle.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP: Doing some cool things with references and destructors</title>
		<link>http://juliusbeckmann.de/blog/php-doing-some-cool-things-with-references-and-destructors.html</link>
		<comments>http://juliusbeckmann.de/blog/php-doing-some-cool-things-with-references-and-destructors.html#comments</comments>
		<pubDate>Sat, 18 Jun 2011 17:56:49 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Destructor]]></category>
		<category><![CDATA[Objects]]></category>
		<category><![CDATA[References]]></category>
		<category><![CDATA[Static Types]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=850</guid>
		<description><![CDATA[Not everybody of you might know, that there are references in PHP too, like in many other languages. I wondered if there is something these references might be really good for and came up with the following concept. References Maybe i should first tell you something about references in PHP: Normally, you do not use [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/php-logo.jpg" alt="php-logo" title="php-logo" width="100" height="55" class="alignright size-full wp-image-855" /><br />
Not everybody of you might know, that there are references in PHP too, like in many other languages. I wondered if there is something these references might be really good for and came up with the following concept.<br />
<span id="more-850"></span></p>
<h3>References</h3>
<p>Maybe i should first tell you something about references in PHP:<br />
Normally, you do not use any of them in your code. You need to use the "&#038;" Operator to create references.<br />
Maybe take a look at the following code to understand:</p>
<div class="codesnip-container" >
<div class="php codesnip" style="font-family:monospace;"><span class="re0">$a</span> <span class="sy0">=</span> <span class="st_h">'test'</span><span class="sy0">;</span><br />
<span class="re0">$b</span> <span class="sy0">=</span> <span class="sy0">&amp;</span> <span class="re0">$a</span><span class="sy0">;</span><br />
<span class="re0">$a</span> <span class="sy0">=</span> <span class="st_h">'abc'</span><span class="sy0">;</span><br />
<span class="kw1">echo</span> <span class="re0">$b</span><span class="sy0">;</span> <span class="co1">// Will output 'abc'</span></div>
</div>
<h3>Object Destructors</h3>
<p>Another important point to know is, when does PHP call the destructor of a object?<br />
PHP does reference counting, that means, if there is no reference pointing at a object, the garbage collector will destroy the object, but before he does so, the __destruct() method of the object will be called.<br />
Some example code for understanding:</p>
<div class="codesnip-container" >
<div class="php codesnip" style="font-family:monospace;"><span class="kw2">class</span> a <span class="br0">&#123;</span><br />
&nbsp; <span class="kw2">public</span> <span class="kw2">function</span> __destruct<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; <span class="kw1">echo</span> <span class="st0">&quot;I go now, bye!&quot;</span><span class="sy0">;</span><br />
&nbsp; <span class="br0">&#125;</span><br />
<span class="br0">&#125;</span><br />
<span class="re0">$a</span> <span class="sy0">=</span> <span class="kw2">new</span> a<span class="br0">&#40;</span><span class="br0">&#41;</span><span class="sy0">;</span><br />
<a href="http://www.php.net/unset"><span class="kw3">unset</span></a><span class="br0">&#40;</span><span class="re0">$a</span><span class="br0">&#41;</span><span class="sy0">;</span> <span class="co1">// Will output &quot;I go now, bye!&quot;</span></div>
</div>
<h3>Concept</h3>
<p>If i combine the two things we know now, how about using references to do some normally impossible things? Like using something to manage references and use our destructor to manipulate the reference that pointed to us before we get destructed?</p>
<p>I realized this with some code you can find here: <a href="https://github.com/JuliusBeckmann/PHP-Reference-Fun">https://github.com/JuliusBeckmann/PHP-Reference-Fun</a></p>
<p>To do so, created the following classes:</p>
<p><strong>ReferenceManager</strong><br />
This static class will collect references, we might use again.</p>
<p><strong>ReferenceType</strong><br />
A abstract class that uses the ReferenceManager to manipulate the outside reference that pointed at us before we got destructed.</p>
<h3>Idea: Write protected objects</h3>
<p><strong>WriteProtected extends ReferenceType</strong><br />
This class uses the ReferenceType destructor call, to recreate itself via the outside reference fetched from ReferenceManager.</p>
<p>Take a look at the source code to fully understand: <a href="https://github.com/JuliusBeckmann/PHP-Reference-Fun/blob/master/ExampleWriteProtected.php">ExampleWriteProtected.php</a></p>
<h3>Idea: Static typed objects</h3>
<p><strong>AbstractStaticType extends ReferenceType</strong><br />
Another thing to know, when our destructor get called, there is no outside reference to out object any more. If there was only, the value it pointed to got overwritten by the new assigned value.<br />
This can be used to manipulate the new value to something we want to have.</p>
<p>Take a look at the source to fully understand: <a href="https://github.com/JuliusBeckmann/PHP-Reference-Fun/blob/master/ExampleStaticTypes.php">ExampleStaticTypes.php</a></p>
<h3>Conclusion</h3>
<p>This whole concept is just a idea proven with some experimental code.<br />
I think there could be several more useful things that can be done with this concept that might help in real life coding hell, but till now, i will just look at it as a neat idea to keep in mind for later.</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/php-doing-some-cool-things-with-references-and-destructors.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubuntu: Create own or fix broken samba shared directorys</title>
		<link>http://juliusbeckmann.de/blog/ubuntu-create-own-or-fix-broken-samba-shared-directorys.html</link>
		<comments>http://juliusbeckmann.de/blog/ubuntu-create-own-or-fix-broken-samba-shared-directorys.html#comments</comments>
		<pubDate>Mon, 30 May 2011 10:28:39 +0000</pubDate>
		<dc:creator>Julius</dc:creator>
				<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Config]]></category>
		<category><![CDATA[Samba]]></category>
		<category><![CDATA[Share]]></category>

		<guid isPermaLink="false">http://juliusbeckmann.de/blog/?p=846</guid>
		<description><![CDATA[I recently wanted to create a shared folder with the attribute hidden, but did not want to change the /etc/samba/smb.cnf. So i searched where the shares created by the gnome folder-properties window where saved. The directory is: /var/lib/samba/usershares/ This is also the place, where you might fix a broken share by deleting the config file.]]></description>
			<content:encoded><![CDATA[<p><img src="http://juliusbeckmann.de/blog/static/ubuntu_logo-194x200.png" alt="ubuntu_logo" title="ubuntu_logo" width="100" height="100" class="alignright size-thumbnail wp-image-806" />I recently wanted to create a shared folder with the attribute hidden, but did not want to change the /etc/samba/smb.cnf.</p>
<p>So i searched where the shares created by the gnome folder-properties window where saved. The directory is:</p>
<p><strong>/var/lib/samba/usershares/</strong></p>
<p>This is also the place, where you might fix a broken share by deleting the config file.</p>
]]></content:encoded>
			<wfw:commentRss>http://juliusbeckmann.de/blog/ubuntu-create-own-or-fix-broken-samba-shared-directorys.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

