Examples of ISVNOptions


Examples of org.tmatesoft.svn.core.wc.ISVNOptions

        }
        return SVNFileUtil.openFileForReading(src, SVNLogType.WC);
    }

    public static File getTranslatedFile(SVNAdminArea dir, String name, File src, boolean forceEOLRepair, boolean useGlobalTmp, boolean forceCopy, boolean toNormalFormat) throws SVNException {
        ISVNOptions options = dir.getWCAccess().getOptions();
        String charset = getCharset(dir.getProperties(name).getStringPropertyValue(SVNProperty.CHARSET), dir.getFile(name).getPath(), options);
        String eolStyle = dir.getProperties(name).getStringPropertyValue(SVNProperty.EOL_STYLE);
        String keywords = dir.getProperties(name).getStringPropertyValue(SVNProperty.KEYWORDS);
        boolean special = dir.getProperties(name).getPropertyValue(SVNProperty.SPECIAL) != null;
        boolean needsTranslation = charset != null || eolStyle != null || keywords != null || special;
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

    public static File maybeUpdateTargetEOLs(SVNAdminArea dir, File target, SVNProperties propDiff) throws SVNException {
        String eolStyle = null;
        if (propDiff != null && propDiff.containsName(SVNProperty.EOL_STYLE) && propDiff.getStringValue(SVNProperty.EOL_STYLE) != null) {
            eolStyle = propDiff.getStringValue(SVNProperty.EOL_STYLE);
            ISVNOptions options = dir.getWCAccess().getOptions();
            byte[] eol = getEOL(eolStyle, options);
            File tmpFile = SVNAdminUtil.createTmpFile(dir);
            copyAndTranslate(target, tmpFile, null, eol, null, false, false, true);
            return tmpFile;
        }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

                }
            }
        }

        File detranslatedFile = null;
        ISVNOptions options = dir.getWCAccess().getOptions();
        String charset = getCharset(charsetProp, dir.getFile(name).getPath(), options);
        if (force || charset != null || keywords != null || eolStyle != null || isSpecial) {
            File tmpFile = SVNAdminUtil.createTmpFile(dir);
            translateToNormalForm(dir.getFile(name), tmpFile, charset, eolStyle, true, keywords, isSpecial);
            detranslatedFile = tmpFile;
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

        }
    }

    private void init() throws SVNException {
        DAVRepositoryFactory.setup();
        ISVNOptions options = SVNWCUtil.createDefaultOptions(true);
        ISVNAuthenticationManager authManager = SVNWCUtil.createDefaultAuthenticationManager(
                SVNWCUtil.getDefaultConfigurationDirectory(), null, null, false);
        manager = SVNClientManager.newInstance(options, authManager);

        tryAuth();
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

    public abstract void run(InputStream in, PrintStream out, PrintStream err) throws SVNException;

    private ISVNOptions getOptions() {
        String dir = (String) getCommandLine().getArgumentValue(SVNArgument.CONFIG_DIR);
        File dirFile = dir == null ? null : new File(dir);
        ISVNOptions options = SVNWCUtil.createDefaultOptions(dirFile, true);
        options.setAuthStorageEnabled(myIsStoreCreds);
        return options;
    }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

        Map keywordsMap = null;
        byte[] eols;
        if (keywords != null) {           
            if (expand) {
                SVNEntry entry = adminArea.getEntry(name, true);
                ISVNOptions options = adminArea.getWCAccess().getOptions();
                String url = entry.getURL();
                String author = entry.getAuthor();
                String date = entry.getCommittedDate();
                String rev = Long.toString(entry.getCommittedRevision());
                keywordsMap = computeKeywords(keywords, url, author, date, rev, options);
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

     * only be read to initialize; to enable changes the readonly flag
     * should be set to false).
     *
     * SVNWCUtil is a utility class that creates a default options driver.
     */
    ISVNOptions options = SVNWCUtil.createDefaultOptions(true);

    /*
     * Creates an instance of SVNClientManager providing authentication
     * information (name, password) and an options driver
     */
 
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

    private File detranslateFile(SVNAdminArea dir, String name) throws SVNException {
        SVNVersionedProperties properties = dir.getProperties(name);
        String keywords = properties.getStringPropertyValue(SVNProperty.KEYWORDS);
        String eolStyle = properties.getStringPropertyValue(SVNProperty.EOL_STYLE);
        String charsetProp = properties.getStringPropertyValue(SVNProperty.CHARSET);
        ISVNOptions options = dir.getWCAccess().getOptions();
        String charset = SVNTranslator.getCharset(charsetProp, dir.getFile(name).getPath(), options);
        boolean special = properties.getPropertyValue(SVNProperty.SPECIAL) != null;
        if (charset == null && keywords == null && eolStyle == null && (!special || SVNFileUtil.isWindows)) {
            return dir.getFile(name);
        }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

    private File detranslateFile(SVNAdminArea dir, String name) throws SVNException {
        SVNVersionedProperties properties = dir.getProperties(name);
        String keywords = properties.getStringPropertyValue(SVNProperty.KEYWORDS);
        String eolStyle = properties.getStringPropertyValue(SVNProperty.EOL_STYLE);
        String charsetProp = properties.getStringPropertyValue(SVNProperty.CHARSET);
        ISVNOptions options = dir.getWCAccess().getOptions();
        String charset = SVNTranslator.getCharset(charsetProp, dir.getFile(name).getPath(), options);
        boolean special = properties.getPropertyValue(SVNProperty.SPECIAL) != null;
        if (charset == null && keywords == null && eolStyle == null && (!special || SVNFileUtil.isWindows)) {
            return dir.getFile(name);
        }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNOptions

        translate(adminArea, name, src, dst, customEOLStyle, false, expand);
    }

    public static void translate(SVNAdminArea adminArea, String name, File src,
                                 File dst, String customEOLStyle, boolean safelyEncode, boolean expand) throws SVNException {
        ISVNOptions options = adminArea.getWCAccess().getOptions();
        SVNVersionedProperties props = adminArea.getProperties(name);
        String keywords = props.getStringPropertyValue(SVNProperty.KEYWORDS);
        String charset = getCharset(props.getStringPropertyValue(SVNProperty.CHARSET), adminArea.getFile(name).getPath(), options);
        String eolStyle = null;
        if (customEOLStyle != null) {
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.