Class ::xo::db::sql::site_node

::xo::db::sql::site_node[i] create ...

Defined in

Class Relations

  • class: ::xo::db::Class[i]
  • superclass: ::xotcl::Object[i]
::xo::db::Class create ::xo::db::sql::site_node \
     -superclass ::xotcl::Object

Methods (to be applied on the object)

  • delete (scripted, public)

     xo::db::sql::site_node[i] delete [ -dbn dbn ] -node_id node_id 

    Automatically generated method

    Switches:
    -dbn (optional)
    -node_id (required)

    Testcases:
    No testcase defined.
    #function_args: {NODE_ID {}}
    foreach var [list NODE_ID]  {
      set varname [string tolower $var]
      if {[info exists $varname]} {
        set $var [set $varname]
        set _$var :$var
      } else {
        set _$var null
      }
    }
    set sql "
    select site_node__delete($_NODE_ID) 
        "
    db_with_handle -dbn $dbn db {
      #ns_log notice "--sql=$sql"
      return [ ns_set value [ns_pg_bind 0or1row $db $sql] 0 ]
    }
  • find_pattern (scripted, public)

     xo::db::sql::site_node[i] find_pattern [ -dbn dbn ] -node_id node_id 

    Automatically generated method

    Switches:
    -dbn (optional)
    -node_id (required)

    Testcases:
    No testcase defined.
    #function_args: {NODE_ID {}}
    foreach var [list NODE_ID]  {
      set varname [string tolower $var]
      if {[info exists $varname]} {
        set $var [set $varname]
        set _$var :$var
      } else {
        set _$var null
      }
    }
    set sql "
    select site_node__find_pattern($_NODE_ID) 
        "
    db_with_handle -dbn $dbn db {
      #ns_log notice "--sql=$sql"
      return [ ns_set value [ns_pg_bind 0or1row $db $sql] 0 ]
    }
  • new (scripted, public)

     xo::db::sql::site_node[i] new [ -dbn dbn ] [ -node_id node_id ] \
        [ -parent_id parent_id ] -name name  [ -object_id object_id ] \
        -directory_p directory_p  [ -pattern_p pattern_p ] \
        [ -creation_user creation_user ] [ -creation_ip creation_ip ] \
        [ -childof childof ]

    Automatically generated method

    Switches:
    -dbn (optional)
    -node_id (optional)
    -parent_id (optional)
    -name (required)
    -object_id (optional)
    -directory_p (required)
    -pattern_p (optional, defaults to "f")
    -creation_user (optional)
    -creation_ip (optional)
    -childof (optional)

    Testcases:
    No testcase defined.
    #function_args: {NODE_ID null} {PARENT_ID null} {NAME {}} {OBJECT_ID null} {DIRECTORY_P {}} {PATTERN_P f} {CREATION_USER null} {CREATION_IP null}
    foreach var [list NODE_ID PARENT_ID NAME OBJECT_ID DIRECTORY_P PATTERN_P CREATION_USER CREATION_IP]  {
      set varname [string tolower $var]
      if {[info exists $varname]} {
        set $var [set $varname]
        set _$var :$var
      } else {
        set _$var null
      }
    }
    set sql "
    select site_node__new($_NODE_ID$_PARENT_ID$_NAME$_OBJECT_ID$_DIRECTORY_P$_PATTERN_P$_CREATION_USER$_CREATION_IP) 
        "
    db_with_handle -dbn $dbn db {
      #ns_log notice "--sql=$sql"
      return [ ns_set value [ns_pg_bind 0or1row $db $sql] 0 ]
    }
  • node_id (scripted, public)

     xo::db::sql::site_node[i] node_id [ -dbn dbn ] -url url  \
        [ -parent_id parent_id ]

    Automatically generated method

    Switches:
    -dbn (optional)
    -url (required)
    -parent_id (optional)

    Testcases:
    No testcase defined.
    #function_args: {URL {}} {PARENT_ID null}
    foreach var [list URL PARENT_ID]  {
      set varname [string tolower $var]
      if {[info exists $varname]} {
        set $var [set $varname]
        set _$var :$var
      } else {
        set _$var null
      }
    }
    set sql "
    select site_node__node_id($_URL$_PARENT_ID) 
        "
    db_with_handle -dbn $dbn db {
      #ns_log notice "--sql=$sql"
      return [ ns_set value [ns_pg_bind 0or1row $db $sql] 0 ]
    }
  • url (scripted, public)

     xo::db::sql::site_node[i] url [ -dbn dbn ] -node_id node_id 

    Automatically generated method

    Switches:
    -dbn (optional)
    -node_id (required)

    Testcases:
    No testcase defined.
    #function_args: {NODE_ID {}}
    foreach var [list NODE_ID]  {
      set varname [string tolower $var]
      if {[info exists $varname]} {
        set $var [set $varname]
        set _$var :$var
      } else {
        set _$var null
      }
    }
    set sql "
    select site_node__url($_NODE_ID) 
        "
    db_with_handle -dbn $dbn db {
      #ns_log notice "--sql=$sql"
      return [ ns_set value [ns_pg_bind 0or1row $db $sql] 0 ]
    }