Refactor some methods to be more re-usable.
Refactor some methods to be more re-usable.

KonajuGames/CppSharp,SonyaSa/CppSharp,txdv/CppSharp,mono/CppSharp,KonajuGames/CppSharp,genuinelucifer/CppSharp,nalkaro/CppSharp,mono/CppSharp,u255436/CppSharp,zillemarco/CppSharp,SonyaSa/CppSharp,ddobrev/CppSharp,mohtamohit/CppSharp,zillemarco/CppSharp,Samana/CppSharp,inordertotest/CppSharp,mono/CppSharp,SonyaSa/CppSharp,xistoso/CppSharp,imazen/CppSharp,mydogisbox/CppSharp,SonyaSa/CppSharp,mohtamohit/CppSharp,ktopouzi/CppSharp,mydogisbox/CppSharp,zillemarco/CppSharp,genuinelucifer/CppSharp,Samana/CppSharp,xistoso/CppSharp,Samana/CppSharp,inordertotest/CppSharp,ddobrev/CppSharp,u255436/CppSharp,xistoso/CppSharp,mohtamohit/CppSharp,mono/CppSharp,KonajuGames/CppSharp,u255436/CppSharp,mono/CppSharp,u255436/CppSharp,imazen/CppSharp,SonyaSa/CppSharp,ktopouzi/CppSharp,nalkaro/CppSharp,Samana/CppSharp,genuinelucifer/CppSharp,mono/CppSharp,mydogisbox/CppSharp,mydogisbox/CppSharp,KonajuGames/CppSharp,genuinelucifer/CppSharp,ddobrev/CppSharp,nalkaro/CppSharp,txdv/CppSharp,xistoso/CppSharp,Samana/CppSharp,ddobrev/CppSharp,inordertotest/CppSharp,KonajuGames/CppSharp,ktopouzi/CppSharp,zillemarco/CppSharp,ddobrev/CppSharp,imazen/CppSharp,inordertotest/CppSharp,u255436/CppSharp,ktopouzi/CppSharp,zillemarco/CppSharp,txdv/CppSharp,txdv/CppSharp,mydogisbox/CppSharp,genuinelucifer/CppSharp,mohtamohit/CppSharp,imazen/CppSharp,nalkaro/CppSharp,nalkaro/CppSharp,ktopouzi/CppSharp,inordertotest/CppSharp,mohtamohit/CppSharp,xistoso/CppSharp,txdv/CppSharp,imazen/CppSharp