From 8e64acf9fe5fd88605b00c7a341b245cb15988fa Mon Sep 17 00:00:00 2001 From: momo5502 Date: Sun, 20 Nov 2016 00:19:17 +0100 Subject: [PATCH] [CodeStyle] Basic naming example [ci skip] --- CODESTYLE.md | 34 +++++++++++++++++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/CODESTYLE.md b/CODESTYLE.md index 6f7a4d40..e07b3869 100644 --- a/CODESTYLE.md +++ b/CODESTYLE.md @@ -1 +1,33 @@ -# Code Style +# Code Style + +```c++ +namespace SomeNamespace +{ + class SomeClass + { + public: + int someVariable; + static int SomeStaticVariable; + + void someMethod() + { + // [...] + } + + static void SomeStaticFunction() + { + // [...] + } + }; +} + +void Main(int argument) +{ + SomeNamespace::SomeClass someObject; + someObject.someVariable = 0; + someObject.someMethod(); + + SomeNamespace::SomeClass::SomeStaticVariable = 0; + SomeNamespace::SomeClass::SomeStaticFunction(); +} +``` \ No newline at end of file