Java Doc for DirectList.java in  » Groupware » hipergate » com » knowgate » crm » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Groupware » hipergate » com.knowgate.crm 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


com.knowgate.crm.DistributionList
   com.knowgate.crm.DirectList

DirectList
public class DirectList extends DistributionList (Code)

DirectList

A subclass of DistributionList with methods for loading List Members from text files.

Copyright: Copyright (c) KnowGate 2003-2006


author:
   Sergio Montoro Ten
version:
   3.0


Field Summary
final public static  intCHECK_INVALID_EMAIL
    
final public static  intCHECK_INVALID_FORMAT
    
final public static  intCHECK_INVALID_NAME
    
final public static  intCHECK_INVALID_SALUTATION
    
final public static  intCHECK_INVALID_SURNAME
    
final public static  intCHECK_NAME_TOO_LONG
    
final public static  intCHECK_OK
    
final public static  intCHECK_SALUTATION_TOO_LONG
    
final public static  intCHECK_SURNAME_TOO_LONG
    
final public static  shortClassId
    

Constructor Summary
public  DirectList()
    
public  DirectList(String sCharSetName)
    

Method Summary
public  interrorLine()
    
public  intgetColumnPosition(String sColumnName)
    
public  StringgetField(int iCol, int iRow)
    

Get value for a field at a given row and column.

Column indexes are zero based.
public  StringgetField(String sCol, int iRow)
    
public  StringgetLine(int iLine)
    

Get line from a parsed file.

Lines are delimited by the Line Feed (LF, CHAR(10), '\n') character
Parameters:
  iLine - Line Number [0..getLineCount()-1] Full Text for Line.
public  intgetLineCount()
    
public  int[]parseFile(String sFilePath, String sFileDescriptor)
     Parse a delimited text file
Parameters:
  sFilePath - File Path
Parameters:
  sFileDescriptor - Delimited Column List.
The only valid column names are { tx_email, tx_name, tx_surname, id_format, tx_salutation }.
Column names may be delimited by ',' ';' or '\t'.Columns names may be quoted.
public  voidremoveFromList(JDCConnection oConn, String sListId)
    
public  voidupdateList(JDCConnection oConn, String sListId, short iStatus)
    

Field Detail
CHECK_INVALID_EMAIL
final public static int CHECK_INVALID_EMAIL(Code)



CHECK_INVALID_FORMAT
final public static int CHECK_INVALID_FORMAT(Code)



CHECK_INVALID_NAME
final public static int CHECK_INVALID_NAME(Code)



CHECK_INVALID_SALUTATION
final public static int CHECK_INVALID_SALUTATION(Code)



CHECK_INVALID_SURNAME
final public static int CHECK_INVALID_SURNAME(Code)



CHECK_NAME_TOO_LONG
final public static int CHECK_NAME_TOO_LONG(Code)



CHECK_OK
final public static int CHECK_OK(Code)



CHECK_SALUTATION_TOO_LONG
final public static int CHECK_SALUTATION_TOO_LONG(Code)



CHECK_SURNAME_TOO_LONG
final public static int CHECK_SURNAME_TOO_LONG(Code)



ClassId
final public static short ClassId(Code)




Constructor Detail
DirectList
public DirectList()(Code)
Default constructor



DirectList
public DirectList(String sCharSetName)(Code)
Constructor
Parameters:
  String - Name of character set to be used when parsing files (ISO-8859-1, UTF-8, etc.)
since:
   3.0




Method Detail
errorLine
public int errorLine()(Code)
Get last error line int



getColumnPosition
public int getColumnPosition(String sColumnName)(Code)

Parameters:
  sColumnName - Column Name Zero based index for column position or -1 if column was not found.



getField
public String getField(int iCol, int iRow) throws ArrayIndexOutOfBoundsException(Code)

Get value for a field at a given row and column.

Column indexes are zero based. Row indexes range from 0 to getLineCount()-1.
Parameters:
  iCol - Column Index
Parameters:
  iRow - Row Index Field Value
throws:
  IllegalStateException - If parseFile() method was not called prior togetField()
throws:
  ArrayIndexOutOfBoundsException - If Column or Row Index is out of bounds.



getField
public String getField(String sCol, int iRow) throws ArrayIndexOutOfBoundsException(Code)

Get value for a field at a given row and column.


Parameters:
  sCol - Column Name
Parameters:
  iRow - Row Name
throws:
  ArrayIndexOutOfBoundsException -



getLine
public String getLine(int iLine) throws IllegalStateException(Code)

Get line from a parsed file.

Lines are delimited by the Line Feed (LF, CHAR(10), '\n') character
Parameters:
  iLine - Line Number [0..getLineCount()-1] Full Text for Line. If iLine<0 or iLine>=getLineCount() then null
throws:
  IllegalStateException - If parseFile() has not been called prior to getLine()



getLineCount
public int getLineCount()(Code)
Get line count after parsing a text file int



parseFile
public int[] parseFile(String sFilePath, String sFileDescriptor) throws ArrayIndexOutOfBoundsException, NullPointerException, IllegalArgumentException, UnsupportedEncodingException, IOException, FileNotFoundException(Code)
Parse a delimited text file
Parameters:
  sFilePath - File Path
Parameters:
  sFileDescriptor - Delimited Column List.
The only valid column names are { tx_email, tx_name, tx_surname, id_format, tx_salutation }.
Column names may be delimited by ',' ';' or '\t'.Columns names may be quoted. Array of status for each parsed line.
CHECK_OKLine is OK
CHECK_INVALID_EMAILtx_email is longer than 100 characters or it is rejected by method Gadgets.checkEMail()
CHECK_NAME_TOO_LONGtx_name is longer than 100 characters
CHECK_INVALID_NAMEtx_name contains forbidden characters { ',' ';' '`' '¨' '?' '"' }
CHECK_SURNAME_TOO_LONGtx_surname is longer than 100 characters
CHECK_INVALID_SURNAMEtx_surname contains forbidden characters { ',' ';' '`' '¨' '?' '"' }
CHECK_INVALID_FORMATid_format is longer than 4 characters
CHECK_SALUTATION_TOO_LONGtx_salutation is longer than 16 characters
CHECK_INVALID_SALUTATIONtx_salutation contains forbidden characters { ',' ';' '`' '¨' '?' '"' }

throws:
  ArrayIndexOutOfBoundsException -
throws:
  FileNotFoundException -
throws:
  IllegalArgumentException -
throws:
  IOException -
throws:
  NullPointerException -
throws:
  UnsupportedEncodingException -
See Also:   com.knowgate.misc.CSVParser



removeFromList
public void removeFromList(JDCConnection oConn, String sListId) throws IllegalArgumentException, SQLException, ClassCastException(Code)

Remove members from a Static, Direct or Black Distribution List.

Members are matched by their e-mail address (tx_email column)
Parameters:
  oConn - Database connection
Parameters:
  sListId - DistributionList GUID
throws:
  IllegalArgumentException - If DistributionList does not exist.
throws:
  ClassCastException - If sListId type is DYNAMIC
throws:
  IllegalStateException - If parseFile() has not been called prior to updateList()
throws:
  SQLException -



updateList
public void updateList(JDCConnection oConn, String sListId, short iStatus) throws IllegalArgumentException, IllegalStateException, ClassCastException, SQLException(Code)

Adds members to a Static, Direct or Black Distribution List.


Parameters:
  oConn - Database connection
Parameters:
  sListId - DistributionList GUID
Parameters:
  iStatus - 1 if loaded members are to be set as active, 0 if loaded member are to be set as unactive.
throws:
  IllegalArgumentException - If DistributionList does not exist.
throws:
  ClassCastException - If sListId type is DYNAMIC.
throws:
  IllegalStateException - If parseFile() has not been called prior to updateList()
throws:
  StringIndexOutOfBoundsException - If a row if malformed
throws:
  SQLException -



Fields inherited from com.knowgate.crm.DistributionList
final public static short ClassId(Code)(Java Doc)
final public static short TYPE_BLACK(Code)(Java Doc)
final public static short TYPE_DIRECT(Code)(Java Doc)
final public static short TYPE_DYNAMIC(Code)(Java Doc)
final public static short TYPE_STATIC(Code)(Java Doc)

Methods inherited from com.knowgate.crm.DistributionList
public String activeCompanies(JDCConnection oConn) throws SQLException(Code)(Java Doc)
public String activeContacts(JDCConnection oConn) throws SQLException(Code)(Java Doc)
public String activeMembers(JDCConnection oConn) throws SQLException, IllegalStateException(Code)(Java Doc)
public void append(JDCConnection oConn, String sListGUID) throws SQLException, IllegalArgumentException, IllegalStateException, ClassCastException(Code)(Java Doc)
public String blackList(JDCConnection oConn) throws SQLException, IllegalStateException(Code)(Java Doc)
public String clone(JDCConnection oConn) throws SQLException(Code)(Java Doc)
public boolean contains(JDCConnection oConn, String sMember) throws SQLException(Code)(Java Doc)
public boolean delete(JDCConnection oConn) throws SQLException(Code)(Java Doc)
public static boolean delete(JDCConnection oConn, String sListGUID) throws SQLException(Code)(Java Doc)
public int memberCount(JDCConnection oConn) throws SQLException(Code)(Java Doc)
public void overwrite(JDCConnection oConn, String sListGUID) throws SQLException, IllegalArgumentException, ClassCastException, IllegalStateException(Code)(Java Doc)
public String print(JDCConnection oConn, boolean bPrintHeader) throws SQLException(Code)(Java Doc)
public boolean store(JDCConnection oConn) throws SQLException(Code)(Java Doc)
public void substract(JDCConnection oConn, String sListGUID) throws SQLException, IllegalArgumentException, IllegalStateException, ClassCastException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.