NotificationFactory.java 1.27 KB
/*
 * Decompiled with CFR 0_118.
 * 
 * Could not load the following classes:
 *  aQute.bnd.annotation.component.Activate
 *  com.adobe.cq.mobile.ui.PushNotificationDataSource
 *  javax.jcr.RepositoryException
 *  org.apache.felix.scr.annotations.Component
 *  org.apache.felix.scr.annotations.Service
 *  org.apache.sling.api.resource.Resource
 *  org.osgi.service.component.ComponentContext
 */
package com.adobe.cq.mobile.ui.impl;

import aQute.bnd.annotation.component.Activate;
import com.adobe.cq.mobile.ui.PushNotificationDataSource;
import com.adobe.cq.mobile.ui.impl.PushNotificationDataSourceImpl;
import javax.jcr.RepositoryException;
import org.apache.felix.scr.annotations.Component;
import org.apache.felix.scr.annotations.Service;
import org.apache.sling.api.resource.Resource;
import org.osgi.service.component.ComponentContext;

@Component(immediate=1, metatype=0)
@Service(value={NotificationFactory.class})
public class NotificationFactory {
    private ComponentContext context;

    public PushNotificationDataSource getNotificationFactory(Resource resource) {
        return new PushNotificationDataSourceImpl(resource, this.context);
    }

    @Activate
    protected void activate(ComponentContext context) throws RepositoryException {
        this.context = context;
    }
}