Package net.wastl.webmail.misc

Examples of net.wastl.webmail.misc.ByteStore


    public HTMLImage(ByteStore content) {
        this.cont=content;
    }

    public HTMLImage(Storage store,String name, Locale locale, String theme) throws WebMailException {
        cont=new ByteStore(store.getBinaryFile(name,locale,theme));
        cont.setContentType(store.getMimeType(name));
        cont.setContentEncoding("BINARY");
    }
View Full Code Here


                        getStorage().getConfig("max attach size"));
                final MultipartParser mparser = new MultipartParser(req, size);
                Part p;
                while ((p = mparser.readNextPart()) != null) {
                    if (p.isFile()) {
                        final ByteStore bs = ByteStore.getBinaryFromIS(
                                ((FilePart) p).getInputStream(), size);
                        bs.setName(((FilePart) p).getFileName());
                        bs.setContentType(getStorage().getMimeType(
                                    ((FilePart) p).getFileName()));
                        http_header.setContent(p.getName(), bs);
                        log.info("File name " + bs.getName());
                        log.info("Type      " + bs.getContentType());

                    } else if (p.isParam()) {
                        http_header.setContent(p.getName(),
                                ((ParamPart) p).getStringValue());
                    }
View Full Code Here

        if(sess == null) {
            throw new WebMailException("No session was given. If you feel this is incorrect, please contact your system administrator");
        }
        WebMailSession session=(WebMailSession)sess;
        //log.debug("Fetching MIME part: "+suburl);
        ByteStore b=session.getMIMEPart(header.getContent("msgid"),suburl.substring(1));
        int count=0;
        while(b == null && count <= 10) {
            //log.debugcount+" ");
            try {
                Thread.sleep(250);
View Full Code Here

TOP

Related Classes of net.wastl.webmail.misc.ByteStore

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.