blob: 7de283c1b4ebba2f6a2d301bcbaf229c4ec784d8 [file] [log] [blame]
adminbae64d82013-08-01 10:50:15 -07001#!/usr/bin/env python
kelvin8ec71442015-01-15 16:57:00 -08002"""
3Created on 22-Nov-2012
adminbae64d82013-08-01 10:50:15 -07004
kelvin8ec71442015-01-15 16:57:00 -08005author:: Anil Kumar ( anilkumar.s@paxterrasolutions.com )
adminbae64d82013-08-01 10:50:15 -07006
7
8 TestON is free software: you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation, either version 2 of the License, or
kelvin8ec71442015-01-15 16:57:00 -080011 ( at your option ) any later version.
adminbae64d82013-08-01 10:50:15 -070012
13 TestON is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
kelvin8ec71442015-01-15 16:57:00 -080019 along with TestON. If not, see <http://www.gnu.org/licenses/>.
adminbae64d82013-08-01 10:50:15 -070020
21
kelvin8ec71442015-01-15 16:57:00 -080022"""
23import struct
24import fcntl
25import os
26import sys
27import signal
28import sys
29import re
30sys.path.append( "../" )
adminbae64d82013-08-01 10:50:15 -070031
32from drivers.component import Component
kelvin8ec71442015-01-15 16:57:00 -080033
34
35class API( Component ):
36
37 """
adminbae64d82013-08-01 10:50:15 -070038 This will define common functions for CLI included.
kelvin8ec71442015-01-15 16:57:00 -080039 """
40 def __init__( self ):
41 super( Component, self ).__init__()
42
43 def connect( self ):
44 """
adminbae64d82013-08-01 10:50:15 -070045 Connection will establish to the remote host using ssh.
46 It will take user_name ,ip_address and password as arguments<br>
kelvin8ec71442015-01-15 16:57:00 -080047 and will return the handle.
48 """
49 super( API, self ).connect()
50
51 return main.TRUE
52