CodeGen
[ class tree: CodeGen ] [ index: CodeGen ] [ all elements ]

Class: CodeGen_Tools_IndentC

Source Location: /CodeGen-1.0.7/CodeGen/Tools/IndentC.php

Class Overview

CodeGen_Tools_Indent
   |
   --CodeGen_Tools_IndentC

C/C++ code specific extension of the Indent class


Author(s):

Version:

  • Release: @package_version@

Copyright:

  • 2005-2008 Hartmut Holzgraefe

Methods


Inherited Variables

Inherited Methods

Class: CodeGen_Tools_Indent

CodeGen_Tools_Indent::dosify()
Change to DOS/Windows line terminators
CodeGen_Tools_Indent::indent()
re-indent a block of text
CodeGen_Tools_Indent::linetrim()
Trim of leading and trailing whitespace-only lines
CodeGen_Tools_Indent::tabify()
Replace leading blanks with tabs
CodeGen_Tools_Indent::untabify()
Replace leading tabs with blanks

Class Details

[line 38]
C/C++ code specific extension of the Indent class

So far the only C/C++ specific stuff is that preprocessor commands require the # to be on the first column



[ Top ]


Method Detail

indent   [line 52]

string indent( int $level, string $text)

re-indent a block of text

with C/C++ we need to make sure that preporcessor directives always start on the first column

  • Return: indented text
  • Access: public

Overrides CodeGen_Tools_Indent::indent() (re-indent a block of text)

Parameters:

int   $level   —  number of leading indent spaces
string   $text   —  text to reindent

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:39:07 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.