Package pt.ist.fenixframework

Examples of pt.ist.fenixframework.DomainObject


*/
public class ReadTeacherByOID {

    protected InfoObject run(String objectId) {
        final String externalId = objectId;
        DomainObject domainObject = FenixFramework.getDomainObject(externalId);
        InfoObject infoObject = null;

        if (domainObject != null) {
            infoObject = InfoTeacher.newInfoFromDomain((Teacher) domainObject);
        }
View Full Code Here


        return collection;
    }

    public ActionForward showThesisDetails(ActionMapping mapping, ActionForm actionForm, HttpServletRequest request,
            HttpServletResponse response) throws Exception {
        DomainObject thesis = getDomainObject(request, "thesisID");
        if (thesis instanceof Thesis) {
            request.setAttribute("thesis", thesis);
            return mapping.findForward("showThesisDetails");
        } else {
            request.getRequestDispatcher("/notFound.jsp").forward(request, response);
View Full Code Here

    }

    // Private Methods

    private Space getSpaceFromParameter(final HttpServletRequest request) {
        final DomainObject obj = getDomainObject(request, "spaceID");
        return obj instanceof Space ? (Space) obj : null;
    }
View Full Code Here

        if (userId == null || payload == null || regId == null) {
            throw new FenixActionException("error.expecting.parameter.not.found");
        }

        final DomainObject object = FenixFramework.getDomainObject(regId);
        if (object instanceof Registration) {
            User user = User.findByUsername(userId);
            Registration registration = (Registration) object;

            if (user.getPrivateKey() != null && user.getPrivateKey().getPrivateKeyValidity() != null) {
View Full Code Here

        if (split.length == 2) {
            String externalId = split[0];
            String className = split[1];
            try {
                Class clazz = Class.forName(className);
                DomainObject domainObject = FenixFramework.getDomainObject(externalId);
                if (domainObject != null && domainObject instanceof CurricularCourseScope) {
                    return ((CurricularCourseScope) domainObject).getDegreeModuleScopeCurricularCourseScope();
                }
                if (domainObject != null && domainObject instanceof Context) {
                    return ((Context) domainObject).getDegreeModuleScopeContext();
View Full Code Here

        return Authenticate.getUser();
    }

    private String getInputTextValue(User userView, String externalId, String labelField) {
        try {
            DomainObject domainObject = FenixFramework.getDomainObject(externalId);

            return BeanUtils.getProperty(domainObject, labelField);

        } catch (Exception ex) {
            throw new RuntimeException("Error getting value for autocomplete component", ex);
View Full Code Here

            String className = (String) this.getAttributes().get("className");
            String labelField = (String) this.getAttributes().get("labelField");

            try {
                DomainObject domainObject = FenixFramework.getDomainObject((String) newValue);

                String correctLabelForExternalId = BeanUtils.getProperty(domainObject, labelField);

                if (correctLabelForExternalId.equals(submittedInputTextValue) == false) {
                    String errorMessage = getMessageFromBundle(context, INVALID_AUTO_COMPLETE_INPUT);
View Full Code Here

@RequestMapping("/thesis")
public class PublicThesisController {

    @RequestMapping("/{thesisId}")
    public String showThesis(@PathVariable String thesisId, Model model) {
        DomainObject obj = FenixFramework.getDomainObject(thesisId);
        if (obj instanceof Thesis) {
            model.addAttribute("thesis", obj);
        }
        return "fenixedu-academic/public/showThesis";
    }
View Full Code Here

TOP

Related Classes of pt.ist.fenixframework.DomainObject

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.