Subversion Repositories XServices

Compare Revisions

Ignore whitespace Rev 31 → Rev 32

/sbm4mylyn/trunk/src/net/brutex/mylyn/sbmconnector/core/SBMClient.java
64,6 → 64,13
private ObjectFactory of;
private List<TableData> tables = new ArrayList<TableData>();
/**
* Instantiates a new SBM client.
* Creates new instance of the aewebservices71 {@link net.brutex.sbm.wsclient.ObjectFactory} and
* initializes web service endpoint from repository url.
*
* @param repository the repository
*/
public SBMClient(TaskRepository repository) {
this.repository = repository;
this.of = new ObjectFactory();
77,6 → 84,13
repository.getRepositoryUrl());
}
/**
* Can authenticate checks if this SBMClient instance has proper authentication details
* set in its related repository. The check is done by invoking the GetUser web service.
*
* @return true, if successful
* @throws CoreException the core exception
*/
public boolean canAuthenticate() throws CoreException {
try {
port.getUser(getAuth(), repository.getCredentials(AuthenticationType.REPOSITORY).getUserName());
88,6 → 102,15
return true;
}
/**
* Gets the SBM items from a table. The result size is limited to 500 and the sorting is done
* by submit date descending.
*
* @param tablename the tablename
* @param sql_where the sql_where
* @return the tT items by table
* @throws CoreException the core exception
*/
public List<TTItem> getTTItemsByTable(String tablename, String sql_where) throws CoreException {
List<TTItem> list = new ArrayList<TTItem>();
if(sql_where==null || sql_where.isEmpty()) sql_where = "TS_ID>0";
106,6 → 129,12
return list;
}
/**
* Gets a SBM item specified by its internal identifier ([tableid:recordid])
*
* @param itemid the itemid
* @return the tT item
*/
public TTItem getTTItem(String itemid) {
TTItem item = of.createTTItem();
try {
242,6 → 271,14
return "UNKNOWN";
}
/**
* Gets the field label. The SBM item is used to determine the table id of
* the table where this field is in.
*
* @param ttitem the ttitem
* @param fieldname the fieldname
* @return the field label
*/
public String getFieldLabel(TTItem ttitem, String fieldname) {
refreshTables();
String itemid = ttitem.getGenericItem().getValue().getItemID().getValue();
279,6 → 316,12
return null;
}
/**
* Gets the notes attached to a SBM item.
*
* @param ttitem the ttitem
* @return the notes
*/
public List<SBMNote> getNotes(TTItem ttitem) {
List<SBMNote> notes = new ArrayList<SBMNote>();
Iterator<Note> iter = ttitem.getNoteList().iterator();
/sbm4mylyn/trunk/src/net/brutex/mylyn/sbmconnector/SBMConnectorPlugin.java
22,11 → 22,22
 
import org.eclipse.core.runtime.Plugin;
 
/**
* The Class SBMConnectorPlugin provides the Mylyn connector for Serena Business Mashups 2009
* SBM2009) plugin.
*/
public class SBMConnectorPlugin extends Plugin {
/** Short SBM version string/ technical identifier. */
public final static String CONNECTOR_KIND = "SBM2009R2.00";
/** Full SBM name and version. */
public final static String DESCRIPTION = "Serena Business Mashups 2009 R2";
/** SBM name without version information */
public final static String LABEL = "Serena Business Mashups";
/** Full, descriptive identifier of this plugin. */
public final static String PLUGIN_ID = "Brutex Network - Mylyn Connector for SBM";
 
}
/sbm4mylyn/trunk/src/net/brutex/mylyn/sbmconnector/package.html
1,7 → 1,13
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head></head>
<head>Mylyn connector for Serena Business Mashups</head>
<body>
Provides...
This eclipse plugin provides a connector for Serena Business Mashups 2009, so that it can be used
in conjunction with Mylyn. Currently only SBM2009R1/ SBM2009R2 and Mylyn 3.3 on Eclipse 3.4 and
Eclipse 3.5 are supported.<br></br>
<i>Please note that Serena and Serena Business Mashups are registered trademarks of
SERENA Software Inc.</i>
<br></br>
This project has not been initiated, lead or supported by Serena.
</body>
</html>