Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Implement IContentManager

Consult the javadoc Javadoc to see which methods must be implemented, globally the following functionality is expected

...

The IContentManagerFactory constis consists of a single method which creates an IContentManager implementation for a given connection. If the given connection is not supported it may raise an exception. To implement this method, you may also need to create your own IConnection which can be used by your content manager.

...

Code Block
@AquimaContentManagerFactory
public class CustomContentManagerFactory implements IContentManagerFactory {
	public IContentManager create(IConnection connection) throws UnsupportedConnectionException {
		if (connection instanceof ICustomConnection) {
			return new CustomContentManager((ICustomConnection) connection);
		} else {
			throw new UnsupportedConnectionException(connection);
		}
	}
}

.NET

From your IWebApplicationPlugin implementation, you may register your factory on the IRegsitractionContext in the Register method.

Code Block
languagec#
public void Register(IRegistrationContext context) {
    context.Register(new CustomContentManagerFactory());
}