Package ag.ion.bion.officelayer.filter

Examples of ag.ion.bion.officelayer.filter.IFilter


   */
  public IFilter[] getFilters() {
    List list = new ArrayList();
    IFilter[] filters = IFilter.FILTERS;
    for(int i=0, n=filters.length; i<n; i++) {
      IFilter filter = filters[i];
      if(filter.isSupported(abstractDocument) && !filter.isExternalFilter())
        list.add(filter);
    }
    return (IFilter[])list.toArray(new IFilter[list.size()]);
  }
View Full Code Here


        IPath filePath = ((IFileEditorInput)editorInput).getFile().getLocation();
        fileExtension = filePath.getFileExtension();
        fileOutputStream = new FileOutputStream(filePath.toOSString());
      }
      if(fileOutputStream != null) {
        IFilter usedFilter = null;
        if(fileExtension != null && fileExtension.length() > 0) {
          IFilter[] filter = document.getFilterProvider().getFilters();
          for(int i = 0; i < filter.length; i++) {
            if(filter[i].getFileExtension(document).equalsIgnoreCase(fileExtension)) {
              usedFilter = filter[i];
View Full Code Here

    if (dialog.open() == Window.CANCEL) {
      return;
    }
     
    final IPath filePath = dialog.getResult();   
    final IFilter filter = dialog.getFilter();
    final IContainer targetContainer = dialog.getTargetContainer();
    if (filePath == null)
      return;     
   
    try {
View Full Code Here

   */
  public IFilter[] getFilters() {
    List list = new ArrayList();
    IFilter[] filters = IFilter.FILTERS;
    for (int i = 0, n = filters.length; i < n; i++) {
      IFilter filter = filters[i];
      if (filter.isSupported(abstractDocument)
          && !filter.isExternalFilter())
        list.add(filter);
    }
    return (IFilter[]) list.toArray(new IFilter[list.size()]);
  }
View Full Code Here

        });
        listFilterDialog.setInput(filtersToUse);
        if(listFilterDialog.open() == Window.OK) {
          Object[] resultFilterType = listFilterDialog.getResult();
          if(resultFilterType.length == 1) {
            IFilter filterType = (IFilter)resultFilterType[0];
            documentDescriptor.setFilterDefinition(filterType.getFilterDefinition(docType));
          }
        }
      }
    }  
  }
View Full Code Here

TOP

Related Classes of ag.ion.bion.officelayer.filter.IFilter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.