zoukankan      html  css  js  c++  java
  • Sharepoint学习笔记—习题系列--70-573习题解析 -(Q118-Q120)

    Question 118
    You are creating a Business Connectivity Services (BCS) entity.
    You need to ensure that all data returned by the entity is available in search results.
    Which type of method instance should you implement?
    A. Finder and GenericInvoker
    B. Finder and IdEnumerator
    C. SpecificFinder and GenericInvoker
    D. SpecificFinder and IdEnumerator

    解析:
     本题想实现:对于使用BCS返回的信息实体具备Sharepoint搜索的能力。
     下面我们分别了解选项中涉及的各个类或接口:
     1.Finder
      Finder 是返回多个实体实例的特殊方法实例。此构造型用于按指定筛选标准读取项的列表。例如,指定名为“Customer”的业务对象时,此方法可用于获取其订单金额在某一范围内的客户列表。
    外部内容类型可以有一个或多个返回多个实例的 Finder 方法。如果没有定义 Finder 方法,则您的外部内容类型无法与 Business Connectivity Services 的演示功能(例如外部列表和业务数据列表 Web 部件)一起使用。

    2.GenericInvoker
    此方法实例将在外部系统上执行任意业务逻辑。
    3. IdEnumerator
      使用外部系统上的 IdEnumerator 方法实例,可以返回表示特定 Entity 的 Entity 实例的标识的字段值。IdEnumerator 输入由方法中包含的筛选器描述符定义,该方法包含 IdEnumerator 以获取 ID(应该可搜索的每个实体的唯一键)的列表。此方法实例允许在 Microsoft SharePoint Server 2010 中搜索外部数据。
    如果需要增量爬网,也必须确保实体的 IdEnumerator 中的返回字段之一表示在外部系统中上一次更新实体实例(在数据库术语中称为“行”)的时间。然后,应使用表示上一次修改日期的 IdEnumerator 的返回值中 TypeDescriptor 的名称来设置外部内容类型的 __BdcLastModifiedTimestamp 属性。
    实体具有零个或一个 IdEnumerator 方法。IdEnumerator 方法不限于返回 ID 的列表。如果它们在返回参数中返回其他字段,则在爬网过程中忽略它们。
    4.SpecificFinder
     SpecificFinder 仅返回一个外部项目。指定某个项目的标识符之后,此构造型可用于读取该项目。例如,指定 Customer 业务对象后,此构造型可用于获取给定客户 ID 的详细客户信息。
    指定标识符之后,外部内容类型应至少具有一个返回单个实例的 SpecificFinder 方法实例。如果未定义外部内容类型的 SpecificFinder 方法实例,则不能对其进行操作,不能对其进行搜索和编制索引,也不能将其用于任何 Business Connectivity Services 演示文稿功能(相关的列表 Web 部件除外)。
    从上面的描述可以看出:IdEnumerator与SpecificFinder均是与Sharepoint的搜索相关的类或接口。
    所以本题目正确选项应该是D
    参考:
    http://msdn.microsoft.com/en-us/library/ff464399.aspx
    http://msdn.microsoft.com/en-us/library/ff464401.aspx
    http://msdn.microsoft.com/zh-cn/library/ff464400(v=office.14).aspx
    http://msdn.microsoft.com/zh-cn/library/ff464398(v=office.14).aspx


    Question 119
    You create a Business Connectivity Services (BCS) object model in Microsoft Visual Studio 2010. The model connects to an XML file.
    You create an external list that displays the BCS entity. You need to ensure that users can delete items from the external list.
    What should you do?
    A. Call the SPList.Delete() method.
    B. Call the SPListItem.Delete() method.
    C. Create a custom method and specify the method as a Deleter method instance.
    D. Create a custom method and specify the method as a Disassociator method instance.

    解析:
      本题意图通过BCS实现在Sharepoint中对外部数据的删除。
      Microsoft Business Connectivity Services (BCS),以前称为业务数据目录(BDC),支持用户从 Microsoft SharePoint 2010 和 Microsoft Office 2010 应用程序的外部系统(通过 Web 服务、数据库以及 Microsoft .NET Framework 程序集)读取和写入数据。
       外部的内容类型的概念是 BCS 的基础。 Windows SharePoint Services 3 引入内容类型概念来描述一个针对列表的可重用的架构。外部的内容类型通过描述架构以及访问外部系统的数据访问功能和其行为来扩展此概念。 所以我们可以认为,外部的内容类型所做的事情包括:映射SharePoint 与外部系统,描述各类实体和数据源的行为。
       所以,我们不可以在代码中直接用Sharepoint中针对列表对象的相关操作方法来实现对外部数据的操作,所有的相关操作都必须采用所谓“隔山打牛”的方式即通过定义外部数据类型以及相关操作(增,删,改)来间接实现对外部数据的操控。因此,选项A.B直接可以排除了,因为它们都是针对Sharepoint自身数据进行的操作方法。
       选项C: Deleter 方法实例用来删除外部数据记录。
       选项D: Disassociator 方法实例可删除给定外部项之间的关系。 此方法并不是用来删除外部数据的。
    所以本题目正确选项应该是C
    参考:
    http://msdn.microsoft.com/en-us/library/ff464327.aspx
    http://msdn.microsoft.com/en-us/library/ff464351.aspx


    Question 120
    You create an entity named Customer in a Business Connectivity Services (BCS) object model.
    You need to ensure that Customer data can be displayed in a Business Data List Web Part.
    Which method type should you use?
    A. Finder
    B. Genericlnvoker
    C. IDEnumerator
    D. SpecificFinder

    解析:
      本题的题意是你在BCS的对象模型中定义了一个名为Customer的实体,你想要此实例能够通过Sharepoint的商用数据列表显示在WebPart中。
      本题提供了4个选项,这4个选项均是Question118的备选项。
      参见Question118对上述4选项的描述。
    所以本题目正确选项应该是A
    参考:
    http://msdn.microsoft.com/en-us/magazine/ee819133.aspx

  • 相关阅读:
    Manager Test and DAO
    07-图
    06-排序
    05-查找
    第04次作业-树
    第03次作业-栈和队列
    week-02 线性表
    week01—绪论
    使用promise封装el-form多个表单校验
    $slot受slot-scope影响,导致$slot中的key消失
  • 原文地址:https://www.cnblogs.com/wsdj-ITtech/p/3164257.html
Copyright © 2011-2022 走看看