正在加载
显示标签为“系统服务优化专家”的博文。显示所有博文
显示标签为“系统服务优化专家”的博文。显示所有博文

Simple Guide & Introduction For ServiceMaster

| 2008年10月20日星期一

What’s Windows Service

On Microsoft Windows operating systems, a Windows service is a long-running executable that performs specific functions and which is designed not to require user intervention. Windows services can be configured to start when the operating system is booted and run in the background as long as Windows is running, or they can be started manually when required. They are similar in concept to a Unix daemon. Many appear in the processes list in the Windows Task Manager, most often with a username of SYSTEM, LOCAL SERVICE or NETWORK SERVICE, though not all processes with the SYSTEM username are services. The remaining services run through svchost.exe as DLLs loaded into memory.

From Wikipedia, the free encyclopedia

Simple Introduction to Service Master

smlogo2副本Service Master is a Windows optimization software which devote to Service Optimization. It can save system resources and improve the efficient by stop or forbid some unnecessary services. Service Master is easy to use even both for freshman and master user.


如果你喜欢本文,把它分享到 Twitter / 校内 / 鲜果 / Digg
或者把它收藏到 Delicious

C#实现支持插件与二次开发的应用程序编写

| 2008年5月23日星期五

CreditDKMILAN副本这两天一直在研究这个插件功能的实现,总结一些心得吧。

首先是应该定义插件应该实现的接口,接口里面是插件需要实现的功能与提供的内容。我是这么设计的:

首先是建立一个新的类库,用于把我们支持的插件的类型都以接口的形式放进去。比如我现在为我的Service Master设计了以下几个插件类型:外观插件,功能插件,系统信息插件,其他类型插件。目前接口设计如下



然后在原有的软件项目(ServiceMaster)中添加了一个插件检测的类,这个类用于检测已经放到Plugin文件夹下的插件。
 
using System;
using System.Collections.Generic;
using System.Text;
using System.Reflection;
using System.IO;
using System.Collections;
namespace ServiceMaster
{
public static class PluginCheck
{
public static IPluginMenu[] getAllPluginsMenu()
{
IPluginInfo[] plugins = getAllPluginsInfo();
List menus = new List();
foreach (IPluginInfo plugin in plugins)
{
if (plugin is IPluginMenu)
menus.Add((IPluginMenu)plugin);
}
return menus.ToArray();
}
public static IPluginInfo[] getAllPluginsInfo()
{
if (Directory.Exists(Directory.GetCurrentDirectory() + @"\Plugin"))
{
string[] files = Directory.GetFiles(Directory.GetCurrentDirectory() + @"\Plugin");
List dlls = new List();
foreach(string file in files)
{
FileInfo info = new FileInfo(file);
if (info.Extension == ".dll")
dlls.Add(getPluginClass(info.Name, "PluginInfo"));
}
return dlls.ToArray();
}
else
{
Directory.CreateDirectory(Directory.GetCurrentDirectory() + @"\Plugin");
return new IPluginInfo[0];
}
}
public static IPluginInfo getPluginClass(string filename,string className)
{
Assembly ass = null;
try
{
ass = Assembly.LoadFrom(@"plugin\" + filename);
}
catch (BadImageFormatException)
{
return null;
}
string nspace=System.IO.Path.GetFileNameWithoutExtension(filename);
Type search = ass.GetType(nspace + "." + className);
if (search==null)
return null;
Object o = Activator.CreateInstance(search);
IPluginInfo info = (IPluginInfo)o;
return info;
}
}
}
 
然后的工作就是就是编写插件了。

得益于.Net平台的CLR,在VS上写出的所有的类库都是可以用的,不管你是用C++还是C#还是其他

就以C#为例说一下写一个插件的步骤


  • 建一个类库

  • 在引用里面添加我们写好的PluginSupport.dll

  • 然后建一个类,类名一定是PluginInfo.cs。记得一定加上using ServcieMaster

  • 然后让这个类实现上面的任意一个或者多个继承于IPluginInfo的接口(也可以只实现IPluginSysInfo,但是那样的话我的ServiceMaster只能认出来是一个插件,但是没有实际功能)

  • 完善功能

  • 编译,生成DLL

  • 把生成的插件放到ServiceMaster的Plugin文件夹下

  • 运行ServiceMaster


这是一个示例的插件
using System;
using System.Collections.Generic;
using System.Text;
using ServiceMaster;
using System.Reflection;

namespace testPlugin
{
public class PluginInfo:IPluginMenu
{
#region IPluginInfo 成员

string IPluginInfo.AutherWebUrl
{
get
{
return "http://dkmilan.72pines.com";
}
}

string IPluginInfo.Author
{
get
{
return "DKMILAN";
}
}

string IPluginInfo.Name
{
get
{
return "TestPlugin";
}
}

string IPluginInfo.Version
{
get { return "1.0.0.0"; }
}
#endregion

#region IPluginMenu 成员

System.Windows.Forms.ToolStripMenuItem IPluginMenu.PluginMenu
{
get
{
System.Windows.Forms.ToolStripMenuItem MenuOne = new System.Windows.Forms.ToolStripMenuItem();
System.Windows.Forms.ToolStripMenuItem MenuTwo = new System.Windows.Forms.ToolStripMenuItem();
System.Windows.Forms.ToolStripMenuItem topMenu = new System.Windows.Forms.ToolStripMenuItem();
//
// MenuOne
//
MenuOne.Name = "MenuOne";
MenuOne.Size = new System.Drawing.Size(148, 22);
MenuOne.Text = "Hello!";
MenuOne.Click += new System.EventHandler(MenuOne_Click);
//
// MenuTwo
//
MenuTwo.Name = "MenuTwo";
MenuTwo.Size = new System.Drawing.Size(148, 22);
MenuTwo.Text = "Hello 2~";
MenuTwo.Click += new System.EventHandler(MenuTwo_Click);
//
// topMenu
//
topMenu.Name = "topMenu";
topMenu.Size = new System.Drawing.Size(148, 22);
topMenu.Text = "插件菜单";
//
topMenu.DropDownItems.Add(MenuOne);
topMenu.DropDownItems.Add(MenuTwo);
return topMenu;
}
}

#endregion

private void MenuOne_Click(object sender, EventArgs e)
{
System.Windows.Forms.MessageBox.Show("Enjoy ServiceMaster!");
}
private void MenuTwo_Click(object sender, EventArgs e)
{
System.Windows.Forms.MessageBox.Show("My Plugin!");
}
}
}

如果你喜欢本文,把它分享到 Twitter / 校内 / 鲜果 / Digg
或者把它收藏到 Delicious

系统服务优化专家 1.7.1.555 修正了几个BUG

| 2008年4月20日星期日

修正了几个bug

更新下载

UpeLink下载

如果你喜欢本文,把它分享到 Twitter / 校内 / 鲜果 / Digg
或者把它收藏到 Delicious

[原创软件]系统服务优化专家 Service Master 1.7.213 发布!

| 2008年4月11日星期五

CreditDKMILAN副本

经过了一个漫长的等待,我的原创系统优化软件,系统服务优化专家 ServiceMaster的新版本1.7.203终于发布了。

关于系统服务优化专家 Service Master

系统服务优化专家是一款针对Windows系统的系统服务进行优化配置,达到系统优化,运行加速的系统优化软件。本软件秉承实用,专业,人性化的原则,本软件可以满足不同类型的用户对系统服务的不同优化要求,安全快速稳定的对系统服务进行优化,达到加快开机速度,减少内存加载,减少无谓的系统消耗。

这次的更新主要包括以下几个内容

  1. 增加了搜索功能,搜索包含指定关键字的服务

  2. 改进了数据库

  3. 更新了部分功能的算法

  4. 添加了更加人性化的右键菜单导出指定服务配置功能

  5. 添加了更加人性化的右键菜单导出指定服务批处理功能

  6. 界面改进,增加了欢迎界面

  7. 界面改进,增加了窗体阴影


注意:本软件需要.net Framework2.0运行环境支持,如果没有请去微软网站下载


Service Master 1.7.213 下载链接

Box.net 91Files.com SkyDrive  大工教育网下载

如果你喜欢本文,把它分享到 Twitter / 校内 / 鲜果 / Digg
或者把它收藏到 Delicious

[原创]系统服务优化专家

| 2008年2月14日星期四

CreditDKMILAN副本系统服务优化专家系统说明

Simple Guide for Service Master

戴柯
Mail:dkmilan#gmail.com
MSN:dkmilan#live.cn
2007-12-1

开发环境
集成编译环境:Visual Studio 2005
语言 :C#

软件简介
本软件秉承实用,专业,人性化的原则,本软件可以满足不同类型的用户对系统服务的不同优化要求。
软件特色
实用!方便!人性化!
服务优化模式多种多样
提供了全面的服务系统信息
提供了专家给出的服务分析和优化建议
适合不同类型的用户
提供了日志功能与保存配置功能,方便误操作的恢复


关于服务
服务是Windows2000/XP/Vista中用于控制Windows系统的硬件设备、内存、文件管理或者其他重要的系统功能的系统组件。这些服务有很大一部分是用户根本不需要的。如果Windows在每次启动时自动加载和运行这些无用的程序或者服务,将延迟系统的启动速度,并会占用了许多宝贵的内存资源。
功能简介
【服务优化】
针对系统中特定服务进行优化,可以改变启动方式和运行状态。

【服务分析】
可以对系统中常见的服务,给出我们专家系统的服务作用分析,以及服务优化意见。通过系统分析方便用户判断一个服务是否为安全或者必要的。
【导入/导出配置】
本功能可以将系统中的当前全部的服务以文件的形式导出,而且随时可以恢复,方便用户在特定情况下快速恢复服务配置的需要。

【向导模式】
对于不懂计算机的用户来说,对系统中纷繁复杂的服务进行优化是十分困难的事情,因此系统服务优化专家为用户提供了向导模式,即使不懂得电脑的人也可以对系统服务进行优化配置。
【自动优化】
本功能可以按照专家的推荐配置对系统进行优化。考虑到用户需求不同,系统服务优化专家提供了两种不同的优化方式:快速优化与深度优化。前者更加稳定安全,适于对系统了解不多的用户,后者的优化则更加深入,适于对系统了解较多,对系统性能要求较高的用户
【批处理优化】
未来满足很多用户经常需要开启关闭某个服务的需求,系统服务优化专家设计了批处理优化模式,可以导出指定服务的批处理文件,方便用户随时使用。系统服务优化专家还特别设计了直接导出常用服务批处理的功能,免去了用户查找服务的麻烦。
【即将完成,添加到软件中的模块】
得益于较为完善的层次化模块化的软件架构,系统服务优化专家的模块添加较为容易,目前即将完成,加入软件中的功能模块包括
 全面升级
 增量升级
 恶意服务检测(用于检测病毒木马)
 Vista服务模块(用于全面支持Vista)

目前版本 ServiceMaster 1.01

如果你喜欢本文,把它分享到 Twitter / 校内 / 鲜果 / Digg
或者把它收藏到 Delicious