资源简介
基于PHP技术 网络课堂学习系统 非常适合用于现在流行的翻转课堂理论哦
代码片段和文件信息
/*
* YUI Compressor
* http://developer.yahoo.com/yui/compressor/
* Author: Julien Lecomte - http://www.julienlecomte.net/
* Author: Isaac Schlueter - http://foohack.com/
* Author: Stoyan Stefanov - http://phpied.com/
* Copyright (c) 2011 Yahoo! Inc. All rights reserved.
* The copyrights embodied in the content of this file are licensed
* by Yahoo! Inc. under the BSD (revised) open source license.
*/
package com.yahoo.platform.yui.compressor;
import java.io.IOException;
import java.io.Reader;
import java.io.Writer;
import java.util.regex.Pattern;
import java.util.regex.Matcher;
import java.util.ArrayList;
public class CssCompressor {
private StringBuffer srcsb = new StringBuffer();
public CssCompressor(Reader in) throws IOException {
// Read the stream...
int c;
while ((c = in.read()) != -1) {
srcsb.append((char) c);
}
}
// Leave data urls alone to increase parse performance.
protected String extractDataUrls(String css ArrayList preservedTokens) {
int maxIndex = css.length() - 1;
int appendIndex = 0;
StringBuffer sb = new StringBuffer();
Pattern p = Pattern.compile(“url\\(\\s*([\“‘]?)data\\:“);
Matcher m = p.matcher(css);
/*
* Since we need to account for non-base64 data urls we need to handle
* ‘ and ) being part of the data string. Hence switching to indexOf
* to determine whether or not we have matching string terminators and
* handling sb appends directly instead of using matcher.append* methods.
*/
while (m.find()) {
int startIndex = m.start() + 4; // “url(“.length()
String terminator = m.group(1); // ‘ “ or empty (not quoted)
if (terminator.length() == 0) {
terminator = “)“;
}
boolean foundTerminator = false;
int endIndex = m.end() - 1;
while(foundTerminator == false && endIndex+1 <= maxIndex) {
endIndex = css.indexOf(terminator endIndex+1);
if ((endIndex > 0) && (css.charAt(endIndex-1) != ‘\\‘)) {
foundTerminator = true;
if (!“)“.equals(terminator)) {
endIndex = css.indexOf(“)“ endIndex);
}
}
}
// Enough searching start moving stuff over to the buffer
sb.append(css.substring(appendIndex m.start()));
if (foundTerminator) {
String token = css.substring(startIndex endIndex);
token = token.replaceAll(“\\s+“ ““);
preservedTokens.add(token);
String preserver = “url(___YUICSSMIN_PRESERVED_TOKEN_“ + (preservedTokens.size() - 1) + “___)“;
sb.append(preserver);
appendIndex = endIndex + 1;
} else {
// No end terminator found re-add the whole match. Should we throw/warn here?
sb.append(css.substring(m.start() m.end()));
appendIndex = m.end();
}
}
sb.append(css.substring(appendIndex));
return sb.toString();
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2015-01-14 10:16 moodle-2.8.2\
目录 0 2015-01-14 10:00 moodle-2.8.2\moodle\
文件 195 2015-01-10 20:12 moodle-2.8.2\moodle\.csslintrc
文件 1228 2015-01-10 20:12 moodle-2.8.2\moodle\.jshintrc
文件 67 2015-01-10 20:12 moodle-2.8.2\moodle\.shifter.json
目录 0 2015-01-14 10:00 moodle-2.8.2\moodle\admin\
文件 2986 2015-01-10 20:12 moodle-2.8.2\moodle\admin\auth.php
文件 7709 2015-01-10 20:12 moodle-2.8.2\moodle\admin\auth_config.php
文件 10184 2015-01-10 20:12 moodle-2.8.2\moodle\admin\blocks.php
文件 6074 2015-01-10 20:12 moodle-2.8.2\moodle\admin\category.php
目录 0 2015-01-14 10:00 moodle-2.8.2\moodle\admin\cli\
文件 3072 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\alternative_component_cache.php
文件 2795 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\automated_backups.php
文件 4089 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\backup.php
文件 1940 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\check_databa
文件 1823 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\cron.php
文件 4387 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\fix_course_sequence.php
文件 3358 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\fix_deleted_users.php
文件 27672 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\install.php
文件 5893 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\install_databa
文件 3704 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\maintenance.php
文件 7463 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\mysql_collation.php
文件 6695 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\mysql_compressed_rows.php
文件 5636 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\mysql_engine.php
文件 1500 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\purge_caches.php
文件 2553 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\reset_password.php
文件 6305 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cli\upgrade.php
文件 3004 2015-01-10 20:12 moodle-2.8.2\moodle\admin\courseformats.php
文件 2780 2015-01-10 20:12 moodle-2.8.2\moodle\admin\cron.php
文件 2716 2015-01-10 20:12 moodle-2.8.2\moodle\admin\editors.php
文件 4361 2015-01-10 20:12 moodle-2.8.2\moodle\admin\enrol.php
............此处省略19558个文件信息
相关资源
- thinkphp使用mpdf导出html为pdf文件
- ThinkPHP5多小区物业管理系统源码系统
- Graphpad Prism7 破解版
- 博客源码资源 源代码 带数据库带后
- php版仿豆瓣源码
- php-7.2.2-Win32-VC15-x64.zip
- PHP课程设计图书管理系统、学生成绩
- MPDF php生成pdf类
- SM2,SM4,SM3国密算法PHP版
- 仿58同城PHP+MYSQL)
- CRMPHP源码,包含主流四个开源crm
- php商城代码源码
- element+thinkphp5+vue
- 基于THINKPHP内核二次开发版在线视频教
- php典型模块与项目实战源代码
- phporacle扩展linux下php安装oracle扩展
- Head First PHP MySQL中文版
- PHP与MySQL程序设计(第4版)(含源码
- 基于ThinkPHP 微名片独立系统源码
- 直播平台PHP源码,内置安装教程,全
- Ecmos(ecmall深度定制的商城购物系统)
- DSMALL商城源码Thinkphp源码B2B2C商城源码
- 跟兄弟连学PHP.azw3
- PHP+Mysql+Html5学生选课系统.zip
- PHP股票配资源码,无加密,带后台
- PHP编程_第3版[programming PHP]完整带书签
- 2018年thinkphp最新直播完整源码
- PHPJM.zip
- 最新微信裂变加粉PHP源码
- 驾校网站PHP
评论
共有 条评论