Examples of UnknownTypeException


Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

                    } else {
                        subview.refresh();
                    }
                }
            } else {
                throw new UnknownTypeException(field.getName());
            }
        }

        // add new fields
        outer2: for (int j = 0; j < flds.size(); j++) {
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

                if (target == null && action.getOnType().isService() || target != null && target.getSpecification().isNotCollection()) {
                    content = new ObjectActionContent(helper);
                } else if (target.getSpecification().isParentedOrFreeCollection()) {
                    content = new CollectionActionContent(helper);
                } else {
                    throw new UnknownTypeException(target);
                }
                final View dialog = Toolkit.getViewFactory().createDialog(content);
                workspace.addDialog(dialog, new Placement(view));
            }
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

    public static ObjectAdapter createAdapter(final Class<?> type, final Object object, final AdapterManager adapterManager, final SpecificationLoader specificationLoader) {
        final ObjectSpecification specification = specificationLoader.loadSpecification(type);
        if (specification.isNotCollection()) {
            return adapterManager.adapterFor(object);
        } else {
            throw new UnknownTypeException("not an object, is this a collection?");
        }
    }
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

            fieldData = facet.toEncodedString(value);
        } else if (field.isOneToOneAssociation()) {
            final ObjectAdapter ref = ((OneToOneAssociation) field).get(object);
            fieldData = createReferenceData(ref);
        } else {
            throw new UnknownTypeException(field);
        }
        data.addField(field.getId(), fieldData);
    }
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

    protected ObjectAdapter createAdapter(final Class<?> type, final Object object) {
        final ObjectSpecification specification = getSpecificationLookup().loadSpecification(type);
        if (specification.isNotCollection()) {
            return getAdapterMap().adapterFor(object);
        } else {
            throw new UnknownTypeException("not an object, is this a collection?");
        }
    }
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

    private ObjectAdapter createAdapter(final Class<?> type, final Object object) {
        final ObjectSpecification specification = getSpecificationLookup().loadSpecification(type);
        if (specification.isNotCollection()) {
            return getAdapterMap().adapterFor(object);
        } else {
            throw new UnknownTypeException("not an object, is this a collection?");
        }
    }
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

                } else {
                    fieldContent[i] = serializeObject2(field, graphDepth - 1, knownObjects);
                }

            } else {
                throw new UnknownTypeException(fields[i]);
            }
        }
        PersistorUtil.end(adapter);
        data.setFieldContent(fieldContent);
        return data;
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

            resultData =
                serializer.serializeCollection(result, serverSideRetrievedObjectGraphDepth, new KnownObjectsRequest());
        } else if (result.getSpecification().isNotCollection()) {
            resultData = encodeCompletePersistentGraph(result);
        } else {
            throw new UnknownTypeException(result);
        }

        return new ExecuteServerActionResponse(resultData, updatesData, disposedData, persistedTargetData,
            persistedParametersData, messages, warnings);
    }
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

        if (adapter == null) {
            return dataFactory.createNullData(type);
        }

        if (!adapter.getSpecification().isNotCollection()) {
            throw new UnknownTypeException(adapter.getSpecification());
        }

        if (adapter.getSpecification().isEncodeable()) {
            return serializer.serializeEncodeable(adapter);
        } else {
View Full Code Here

Examples of org.apache.isis.core.commons.exceptions.UnknownTypeException

                messages.add(0, "Action returned: " + result.titleString());
                request.forward(ForwardRequest.viewObject(targetId));
            } else if (result.getSpecification().isNotCollection()) {
                forwardObjectResult(request, context, result);
            } else {
                throw new UnknownTypeException(result.getSpecification().getFullIdentifier());
            }
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.