惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Attack and Defense Labs
Attack and Defense Labs
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
The Hacker News
The Hacker News
C
Cyber Attacks, Cyber Crime and Cyber Security
A
Arctic Wolf
Recent Commits to openclaw:main
Recent Commits to openclaw:main
T
Troy Hunt's Blog
小众软件
小众软件
L
LangChain Blog
Schneier on Security
Schneier on Security
D
DataBreaches.Net
爱范儿
爱范儿
P
Proofpoint News Feed
博客园 - 聂微东
M
MIT News - Artificial intelligence
Hacker News: Ask HN
Hacker News: Ask HN
T
Tailwind CSS Blog
Vercel News
Vercel News
V
Visual Studio Blog
aimingoo的专栏
aimingoo的专栏
云风的 BLOG
云风的 BLOG
Jina AI
Jina AI
阮一峰的网络日志
阮一峰的网络日志
博客园 - 【当耐特】
博客园 - 三生石上(FineUI控件)
雷峰网
雷峰网
T
Threat Research - Cisco Blogs
Simon Willison's Weblog
Simon Willison's Weblog
月光博客
月光博客
Spread Privacy
Spread Privacy
C
Cisco Blogs
S
Securelist
量子位
S
Security @ Cisco Blogs
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
T
Tenable Blog
WordPress大学
WordPress大学
T
The Exploit Database - CXSecurity.com
宝玉的分享
宝玉的分享
C
Cybersecurity and Infrastructure Security Agency CISA
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
MongoDB | Blog
MongoDB | Blog
C
CERT Recently Published Vulnerability Notes
Help Net Security
Help Net Security
酷 壳 – CoolShell
酷 壳 – CoolShell
博客园 - 司徒正美
B
Blog RSS Feed
博客园_首页
Security Archives - TechRepublic
Security Archives - TechRepublic
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org

博客园 - 永春

随笔 随笔 asp+access在64位上的问题 换个活法 项目做的很无语 五分钟叫你看懂美国金融危机的成因和巨大危害[转] Sqlserver中的日期类型值不能小于1753年 C#读取WORD时发生“拒绝访问”及“消息筛选器显示应用程序正在使用中”异常的处理 Asp.Net之自定义表达式构造器(ExpressionBuilder) [Sharepoint2007对象模型]第三回:Web应用程序(SPWebApplication) Sharepoint2007对象模型系列 [Sharepoint2007对象模型]第一回:服务器场(SPFarm) C#强化系列文章九:代码访问安全性使用 项目经理的个人修养 《博客园精华集--Sharepoint分册》第三轮结果 《博客园精华集》Sharepoint+MOSS分册第2轮筛选结果文章列表 Asp.Net页面执行流程分析 C#强化系列文章八:HttpModule,HttpHandler,HttpHandlerFactory简单使用 在MOSS中使用.Net3.5中的Ajax功能
[Sharepoint2007对象模型]第二回:Web应用程序服务(SPWebService)
永春 · 2008-07-31 · via 博客园 - 永春

在上一回中说了Sharepoint中的服务器场,在服务器场中最重要的一个服务就是Web应用程序服务。我们自己的Sharepoint网站都是借助于这个服务才能正常运行的,也就是说所有的Sharepoint站点都是搭建在这个服务之上的。Web应用程序服务对应的对象模型为:SPWebService,本回就主要说说这个对象模型。

 Web应用程序服务取得方式请参考第一回,它主要包含以下几个对象模型:
1、Web应用程序,指的是在这个Web应用程序服务下放置的几个web应用程序,也就是在Sharepoint的管理中心创建的web应用程序

对应的对象模型为:SPWebApplicatio

            TreeNode nodeWebApp = nodeWeb.Nodes.Add("Web应用程序");
            
foreach (SPWebApplication app in webServices.WebApplications)
            {
                TreeNode nodeOneWeb 
= nodeWebApp.Nodes.Add(app.DisplayName);
                ShowWebApplication(app, nodeOneWeb);
            }

ShowWebApplication是用来取得这个web应用程序信息的,比如这个web应用程序包含几个站点集等,下回分解:)

2、属性集,用来定义此服务包含哪些属性

            TreeNode nodeProperty = nodeWeb.Nodes.Add("属性集");
            
foreach (DictionaryEntry entry in webServices.Properties)
            {
                nodeProperty.Nodes.Add(entry.Key.ToString());
            }

3、应用程序池,指的是此Web服务使用的是哪个应用程序池,在创建Web应用程序时会指定一个应用程序池,也就是在IIS中的应用程序池,一般不同的web应用程序最好使用不同的应用程序池。
对应的对象模型为:SPApplicationPool

            TreeNode nodeAppPool = nodeWeb.Nodes.Add("应用程序池");
            
foreach (SPApplicationPool appPool in webServices.ApplicationPools)
            {
                nodeAppPool.Nodes.Add(appPool.DisplayName);
            }

4、网站配额模板,指的是对某个子网站的配额限制,特别是对个人网站需要指定每个个人网站所允许的大小,在sharepoint的管理中心可以看到:

对应的对象模型为:SPQuotaTemplate

            TreeNode nodeQuota = nodeWeb.Nodes.Add("网站配额模板");
            
foreach (SPQuotaTemplate quota in webServices.QuotaTemplates)
            {
                nodeQuota.Nodes.Add(quota.Name);
            }  


执行后的画面如下:

小结:本回介绍了Web应用程序服务的对象模型,这些可能都是一些比较大的概念,下回介绍Web应用程序的对象模型,离我们自己的网站对象模型越来越近了:)