Examples of toFormattedString()


Examples of org.apache.directory.studio.ldifparser.model.lines.LdifCommentLine.toFormattedString()

                .write( LdifCommentLine
                    .create(
                        "#!CONNECTION ldap://" + browserConnection.getConnection().getHost() + ":" + browserConnection.getConnection().getPort() ).toFormattedString( LdifFormatParameters.DEFAULT ) ); //$NON-NLS-1$ //$NON-NLS-2$
            logWriter.write( LdifCommentLine
                .create( "#!DATE " + df.format( new Date() ) ).toFormattedString( LdifFormatParameters.DEFAULT ) ); //$NON-NLS-1$
            logWriter.write( errorCommentLine.toFormattedString( LdifFormatParameters.DEFAULT ) );
            logWriter.write( record.toFormattedString( ldifFormatParameters ) );
        }
        catch ( IOException ioe )
        {
            monitor.reportError( BrowserCoreMessages.model__error_logging_modification, ioe );
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifCommentLine.toFormattedString()

            {
                String errorComment = "#!ERROR " + ex.getMessage(); //$NON-NLS-1$
                errorComment = errorComment.replaceAll( "\r", " " ); //$NON-NLS-1$ //$NON-NLS-2$
                errorComment = errorComment.replaceAll( "\n", " " ); //$NON-NLS-1$ //$NON-NLS-2$
                LdifCommentLine errorCommentLine = LdifCommentLine.create( errorComment );
                logger.log( Level.ALL, errorCommentLine.toFormattedString( LdifFormatParameters.DEFAULT ) );
            }

            logger.log( Level.ALL, text );
        }
    }
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifCommentLine.toFormattedString()

            {
                String errorComment = "#!ERROR " + ex.getMessage(); //$NON-NLS-1$
                errorComment = errorComment.replaceAll( "\r", " " ); //$NON-NLS-1$ //$NON-NLS-2$
                errorComment = errorComment.replaceAll( "\n", " " ); //$NON-NLS-1$ //$NON-NLS-2$
                LdifCommentLine errorCommentLine = LdifCommentLine.create( errorComment );
                logger.log( Level.ALL, errorCommentLine.toFormattedString( LdifFormatParameters.DEFAULT ) );
            }

            logger.log( Level.ALL, text );
        }
    }
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifModSpecSepLine.toFormattedString()

                            String text = newTypeLine.toFormattedString( Utils.getLdifFormatParameters() );
                            for ( int j = 0; j < newAttrValLines.length; j++ )
                            {
                                text += newAttrValLines[j].toFormattedString( Utils.getLdifFormatParameters() );
                            }
                            text += newSepLine.toFormattedString( Utils.getLdifFormatParameters() );
                            try
                            {
                                document.replace( modSpec.getOffset(), modSpec.getLength(), text );
                            }
                            catch ( BadLocationException e )
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifModSpecTypeLine.toFormattedString()

                            }

                            LdifModSpecSepLine newSepLine = LdifModSpecSepLine.create();

                            String text = newTypeLine.toFormattedString( Utils.getLdifFormatParameters() );
                            for ( int j = 0; j < newAttrValLines.length; j++ )
                            {
                                text += newAttrValLines[j].toFormattedString( Utils.getLdifFormatParameters() );
                            }
                            text += newSepLine.toFormattedString( Utils.getLdifFormatParameters() );
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifSepLine.toFormattedString()

            // add version spec
            LdifVersionLine ldifVersionLine = LdifVersionLine.create();
            String ldifVersionLineString = ldifVersionLine.toFormattedString( ldifFormatParameters );
            bufferedWriter.write( ldifVersionLineString );
            LdifSepLine ldifSepLine = LdifSepLine.create();
            String ldifSepLineString = ldifSepLine.toFormattedString( ldifFormatParameters );
            bufferedWriter.write( ldifSepLineString );

            // add the records
            while ( !monitor.isCanceled() && !monitor.errorsReported() && enumeration.hasNext() )
            {
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifValueLineBase.toFormattedString()

                        }
                    }

                    try
                    {
                        document.replace( line.getOffset(), line.getLength(), newLine.toFormattedString( Utils
                            .getLdifFormatParameters() ) );
                    }
                    catch ( BadLocationException e )
                    {
                        e.printStackTrace();
View Full Code Here

Examples of org.apache.directory.studio.ldifparser.model.lines.LdifVersionLine.toFormattedString()

            JndiLdifEnumeration enumeration = search( browserConnection, searchParameter, monitor );
            LdifFormatParameters ldifFormatParameters = Utils.getLdifFormatParameters();

            // add version spec
            LdifVersionLine ldifVersionLine = LdifVersionLine.create();
            String ldifVersionLineString = ldifVersionLine.toFormattedString( ldifFormatParameters );
            bufferedWriter.write( ldifVersionLineString );
            LdifSepLine ldifSepLine = LdifSepLine.create();
            String ldifSepLineString = ldifSepLine.toFormattedString( ldifFormatParameters );
            bufferedWriter.write( ldifSepLineString );
View Full Code Here

Examples of org.glite.authz.pap.common.Pap.toFormattedString()

        Pap pap = new Pap(alias, isLocal, dn, host, port, path, protocol, isPublic);

        String msg = "Updating PAP: ";

        if (verboseMode) {
            System.out.println(msg + pap.toFormattedString(0, msg.length()));
        }

        if (!(papMgmtClient.exists(pap.getAlias()))) {
            System.out.println("PAP doesn't exists.");
            return ExitStatus.FAILURE.ordinal();
View Full Code Here

Examples of org.glite.authz.pap.common.xacml.wizard.PolicySetWizard.toFormattedString()

         
          System.out.println(policySetWizard.toXACMLString());
       
        } else {
         
          System.out.println(policySetWizard.toFormattedString(
              showIds, showRuleId));
        }

      } catch (UnsupportedPolicySetWizardException e) {
        log.error("Unsupported Policy/PolicySet", e);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.