-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CQ-10370 - Write code samples showing how to extend the Hybris connector
re-structuring the modules
- Loading branch information
1 parent
5f9b121
commit b452097
Showing
19 changed files
with
81 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,30 @@ | ||
cq-hybris-extensions | ||
==================== | ||
My Project | ||
======== | ||
|
||
This a content package project generated using the multimodule-content-package-archetype. | ||
|
||
Building | ||
-------- | ||
|
||
This project uses Maven for building. Common commands: | ||
|
||
From the root directory, run ``mvn -PautoInstallPackage clean install`` to build the bundle and content package and install to a CQ instance. | ||
|
||
From the bundle directory, run ``mvn -PautoInstallBundle clean install`` to build *just* the bundle and install to a CQ instance. | ||
|
||
Using with VLT | ||
-------------- | ||
|
||
To use vlt with this project, first build and install the package to your local CQ instance as described above. Then cd to `content/src/main/content/jcr_root` and run | ||
|
||
vlt --credentials admin:admin checkout -f ../META-INF/vault/filter.xml --force http://localhost:4502/crx | ||
|
||
Once the working copy is created, you can use the normal ``vlt up`` and ``vlt ci`` commands. | ||
|
||
Specifying CRX Host/Port | ||
------------------------ | ||
|
||
The CRX host and port can be specified on the command line with: | ||
mvn -Dcrx.host=otherhost -Dcrx.port=5502 <goals> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
40 changes: 40 additions & 0 deletions
40
bundle/src/main/java/com/mycompany/myproject/MyImportHandler.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/************************************************************************* | ||
* | ||
* ADOBE CONFIDENTIAL | ||
* __________________ | ||
* | ||
* Copyright 2013 Adobe Systems Incorporated | ||
* All Rights Reserved. | ||
* | ||
* NOTICE: All information contained herein is, and remains | ||
* the property of Adobe Systems Incorporated and its suppliers, | ||
* if any. The intellectual and technical concepts contained | ||
* herein are proprietary to Adobe Systems Incorporated and its | ||
* suppliers and are protected by trade secret or copyright law. | ||
* Dissemination of this information or reproduction of this material | ||
* is strictly forbidden unless prior written permission is obtained | ||
* from Adobe Systems Incorporated. | ||
**************************************************************************/ | ||
package com.mycompany.myproject; | ||
|
||
import javax.jcr.Node; | ||
|
||
import com.adobe.cq.commerce.hybris.importer.DefaultImportHandler; | ||
import com.adobe.cq.commerce.hybris.importer.ImportHandler; | ||
import com.adobe.cq.commerce.hybris.importer.ImporterContext; | ||
import org.apache.felix.scr.annotations.Component; | ||
import org.apache.felix.scr.annotations.Service; | ||
import org.apache.sling.api.resource.ValueMap; | ||
|
||
/** | ||
* Customized import handler for Hybris product catalogs. | ||
*/ | ||
@Component(metatype = true, label = "Customized Commerce Hybris Import Handler") | ||
@Service | ||
public class MyImportHandler extends DefaultImportHandler implements ImportHandler { | ||
|
||
public void updateAsset(Node imageNode, ImporterContext ctx, ValueMap values) throws Exception { | ||
// put your code here | ||
} | ||
|
||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters