Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

svn commit: r523183 - in /lenya/branches/BRANCH_1_2_X/src/java/org/apache/l: msg#00030

cms.lenya.cvs

Subject: svn commit: r523183 - in /lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya: cms/ant/StaticHTMLExporter.java net/WGet.java

Author: antonio
Date: Tue Mar 27 22:38:45 2007
New Revision: 523183

URL: http://svn.apache.org/viewvc?view=rev&rev=523183
Log:
Extract imports.

Modified:

lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/ant/StaticHTMLExporter.java
lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/net/WGet.java

Modified:
lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/ant/StaticHTMLExporter.java
URL:
http://svn.apache.org/viewvc/lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/ant/StaticHTMLExporter.java?view=diff&rev=523183&r1=523182&r2=523183
==============================================================================
---
lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/ant/StaticHTMLExporter.java
(original)
+++
lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/cms/ant/StaticHTMLExporter.java
Tue Mar 27 22:38:45 2007
@@ -25,6 +25,7 @@
import java.net.URL;

import org.apache.lenya.cms.publishing.ExportException;
+import org.apache.lenya.net.WGet;
import org.apache.tools.ant.BuildException;


@@ -141,7 +142,7 @@
exportDirectory.mkdirs();
}

- org.apache.lenya.net.WGet wget = new org.apache.lenya.net.WGet();
+ WGet wget = new WGet();
wget.setDirectoryPrefix(exportDirectory.getAbsolutePath());

String fullServerURI = serverURI.toString();

Modified: lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/net/WGet.java
URL:
http://svn.apache.org/viewvc/lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/net/WGet.java?view=diff&rev=523183&r1=523182&r2=523183
==============================================================================
--- lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/net/WGet.java
(original)
+++ lenya/branches/BRANCH_1_2_X/src/java/org/apache/lenya/net/WGet.java Tue Mar
27 22:38:45 2007
@@ -32,6 +32,9 @@
import java.util.Iterator;
import java.util.List;

+import org.apache.lenya.util.HTML;
+import org.apache.lenya.util.SED;
+import org.apache.lenya.util.URLUtil;
import org.apache.log4j.Logger;

/**
@@ -146,7 +149,7 @@
String link = (String) iterator.next();

try {
- URL child_url = new
URL(org.apache.lenya.util.URLUtil.complete(url.toString(),
+ URL child_url = new URL(URLUtil.complete(url.toString(),
link));

byte[] child_sresponse = getResource(child_url);
@@ -192,7 +195,7 @@
List links = null;

try {
- org.apache.lenya.util.HTML html = new
org.apache.lenya.util.HTML(url.toString());
+ HTML html = new HTML(url.toString());
links = html.getImageSrcs(false);
links.addAll(html.getLinkHRefs(false));
} catch (Exception e) {
@@ -218,7 +221,7 @@
public void substitutePrefix(String filename, String prefixSubstitute,
String substituteReplacement) throws IOException {
log.debug("Replace " + prefixSubstitute + " by " +
substituteReplacement);

- org.apache.lenya.util.SED.replaceAll(new File(filename),
escapeSlashes(prefixSubstitute), escapeSlashes(substituteReplacement));
+ SED.replaceAll(new File(filename), escapeSlashes(prefixSubstitute),
escapeSlashes(substituteReplacement));
}

/**
@@ -283,10 +286,10 @@
public byte[] runProcess(String command) throws Exception {
Process process = Runtime.getRuntime().exec(command);

- java.io.InputStream in = process.getInputStream();
+ InputStream in = process.getInputStream();
byte[] buffer = new byte[1024];
int bytes_read = 0;
- java.io.ByteArrayOutputStream baout = new
java.io.ByteArrayOutputStream();
+ ByteArrayOutputStream baout = new ByteArrayOutputStream();

while ((bytes_read = in.read(buffer)) != -1) {
baout.write(buffer, 0, bytes_read);
@@ -297,8 +300,8 @@
"END:InputStream%%%");
}

- java.io.InputStream in_e = process.getErrorStream();
- java.io.ByteArrayOutputStream baout_e = new
java.io.ByteArrayOutputStream();
+ InputStream in_e = process.getErrorStream();
+ ByteArrayOutputStream baout_e = new ByteArrayOutputStream();

while ((bytes_read = in_e.read(buffer)) != -1) {
baout_e.write(buffer, 0, bytes_read);


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
qplus.devel/200...    network.jabber....    debian.qa-packa...    encryption.gpg....    python.dabo.dev...    uclinux.devel/2...    science.mathema...    recreation.pesc...    kernel.ck/2004-...    mozilla.devel.e...    tex.latex.prosp...    ietf.multi6/200...    bbc.cvs/2002-11...    xfree86.newbie/...    jakarta.taglibs...    altlinux.hardwa...    comedi/2002-05/...    horde.bugs/2004...    games.diplomacy...    finance.e-gold....    web.dom.test-su...    lang.ruby.rails...    os.netbsd.devel...    video.gstreamer...   
Home | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation