Quantcast
Channel: SCN : All Content - SAP BusinessObjects Design Studio
Viewing all articles
Browse latest Browse all 4216

SDK Development Community Git Repository (sdkpackage)

$
0
0

This blog is targeted to everyone who wants to clone the repository with the community components.

 

The Repository

we use normal repository at GitHub, you need a  user on GitHub.com to be able to clone this repository.

 

Clone URL:

https://github.com/org-scn-design-studio-community/sdkpackage.git

 

After cloning the repository, you can import all projects which are in the repository. WE have following folder structure:

folders.PNG

  • .git - standard git folder
  • features - the folder for feature definition (one for 1.3, one with data sources for 1.4)
  • script - main generation script (below more details)
  • src - sources for the bundles.

 

Source Structure

there are currently 6 packages, with following content:

Capture.PNG

  • basics - all components with manual content filling (no data binding)
  • databound - components which are bound to data
  • datasource - the package with data sources, this one is compatible with 1.4 only
  • prototypes - something what is not (yet) for productive usage
  • shared - this package is for shared scripts, and other shared obejcts
  • utils - non-ui components

 

Package Structure

Every package has following structure:

Capture.PNG

 

When you take a look on "res" folder, you will see many components, one subfolder per component, e.g.

Capture.PNG

For demonstration purposes I have created the "DummyControl" folder, actually I should call this just "Dummy" to have the name in sync..


Component Structure

The basic concept is, all components are self contained - this means all editing is placed in the specific component folder. The structure of this folder is as given below. The component folder is located always in "res" folder, e.g.:

Capture.PNG

We do not set any specific naming conventions, just make this "similar" to other components.

 

in the component folder, there are 2 subfolders, and the JS file and image file.

For content of those files, look at the uploaded Dummy in the templates

- sdkpackage/templates/basic_component_template/Dummy at master · org-scn-design-studio-community/sdkpackage · GitHub

Capture.PNG

  • in aps fodler place all files related to "Advanced Property Sheet"
  • in def folder place the definition files, meaning
    • contribution.xml
    • contribution.ztl
  • then in the main folder place the JS files you require to run the folder

 

Script (for generation)

As the SDK infrastructure requires only one contribution.xml and contribution.ztl per package, we just generate it. This means, when you have created a new component, you need to "register" it in the build.cmd, you need to add 2 lines, like here for the "Dummy" control.


one line for inclusion into "contribution.xml"

Capture.PNG

and one for inclusion into "contribution.ztl"

Capture.PNG

Then you should execute the script, and the main contribution files will be updated.

 

This procedure allows easy editing in own folder to avoid collisions.

 

Control Definition

You can use the Dummy package, I will upload the content into repository as template, see here:

<repo-root>\templates\basic_component_template\Dummy

 

this control was created in the "basis" package, you need to assure you have replaced all parts also in the packaging when using as template in databound, e.g. org.scn.community.basics.Dummy must be changed to org.scn.community.databound.Dummy.

 

Special Folders - /OS

to allow reuse, we have the "os" folder to place there all other open source components, keep the license there and assure also some link which helps to know where is this coming from.

 

Important Specialities

  • the component contribution.xml and contribution.ztl files MUST start and end with EMPTY LINE, this is for better concatenation
  • when changed something in contribution files, do not forget to re-run the build.cmd script...
  • assure your setting is "autocrlf"="true" (other case everyone will be collisioning on linebreaks

 

I hope this describes the basics..


Reading that you should be able to

  • import the repository
  • add new component
  • include the component into the package
  • start Design Studio in debug mode with your component

 

For those who have 20 minutes to look at the video (setting up repository and creating Dummy component)

https://raw.githubusercontent.com/org-scn-design-studio-community/tutorials/master/importing_repository_creating_compone…


Viewing all articles
Browse latest Browse all 4216

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>